搜索列名你好,
我需要搜索其中包含字符串“fo”的列名称,并在 Y,Columns 中选择这些列。
我如何将其包含在 JSL 中?
对此的任何帮助将非常感激

谢谢,
杰克
高级统计建模自动化和脚本编写质量和工艺工程回复:搜索列名称这需要是一个 OR 子句
If(Contains(colList[i], "SS") |
Contains(colList[i], "SE"),
Insert Into(filteredCols, colList[i])
);
回复:搜索列名称星期三快乐@jthi ,
我试图添加另一个包含语句过滤包含该字符串的所有列“SE”但它似乎没有按预期工作。
我添加了if 循环中包含(colList[i], "SE")有什么想法吗?
Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Water Treatment.jmp");
colList = dt << Get Column Names("String");
filteredCols = {};
For(i = 1, i <= N Items(colList), i++,
If(Contains(colList[i], "SS"),
Contains(colList[i], "SE"),
Insert Into(filteredCols, colList[i]))
);
obj = dt <<
Explore Outliers(
Y((Eval(filteredCols) )));
obj << Tail Quantile( 0.1 );
obj << Quantile Range Outliers;
obj<< Select Rows(All);
谢谢,
杰克
回复:搜索列名称我认为脚本索引可以让你非常接近:

我通常不建议删除 JMP 中的行,隐藏和排除通常是更好的选择。
回复:搜索列名称我想选择并删除那些特定的行。 如何包含在 jsl 脚本中?

Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Water Treatment.jmp");
colList = dt << Get Column Names("String");
filteredCols = {};
For(i = 1, i <= N Items(colList), i++,
If(Contains(colList[i], "SS"), Insert Into(filteredCols, colList[i]))
);
dt << Explore Outliers(Y(Eval(filteredCols)),
Show only columns with outliers( 1 )
,Quantile Range Ouliers
);回复:搜索列名称这是 JMP16 中的新功能。
您必须使用 For 循环才能在 JMP15 中获得相同的结果。
像这样的东西:
filteredCols = {};
For(i = 1, i <= N Items(colList), i++,
If(Contains(colList[i], "SS"), Insert Into(filteredCols, colList[i]))
);回复:搜索列名称非常感谢@jthi
我不确定 JMP 15 是否支持 Filter Each 命令。 我尝试了该脚本,但它给了我一个错误

回复:搜索列名称下面是一个示例,其中所有包含 SS 的列都添加到对话框中:
Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Water Treatment.jmp");
colList = dt << Get Column Names("String");
a = Filter Each({value}, colList, Contains(value, "SS"));
obj = dt << Explore Outliers(Y(Eval(a)));
obj << Relaunch Analysis;
obj << Close Window();