我有一个数据集,其中有条件并进行了不同的测量。
例如:
性别 年龄 身高 鞋码
男 20 66 英寸 10
女 18 60 英寸 8
我正在制作一个脚本来查看分布和变化。 我想制作身高和鞋码的图表(分别)。 在某些情况下,我有一些身高异常值(让我们假设),但鞋码仍然有效。 我必须在我的脚本中添加哪行代码,才能不在我的一个脚本中包含异常行...但将其包含在我的其他脚本中? 如果我使用隐藏/排除,它会完全消失并且不会显示在任何图表中。 我想控制哪些图表显示哪些行。 我正在使用变异量表和分布图。
你好@莫查尔
至少有两种方法可以实现您想要的功能。
首先,您可以对要过滤的图表单独使用“本地数据过滤器”。这不会影响其他地块。
另一个选项是通过使用或不使用“自动重新计算”来操纵执行的“计时”。
看看这个脚本,让我们知道它是否有帮助。
names default to here (1);
Open( "$SAMPLE_DATA/Big Class.jmp" );
New Window( "Big Class - Variability Chart of height, weight by sex",
h list box (V List Box(
Variability Chart(
Automatic Recalc( 1 ),
Y( :height ),
X( :sex ),
Model( "Main Effect" ),
Variability Summary Report( 1 ),
Points Jittered( 1 )
),
Variability Chart(
Automatic Recalc( 1 ),
Y( :weight ),
X( :sex ),
Variability Summary Report( 1 ),
Mean of Std Dev( 1 ),
Points Jittered( 1 )
)
),
Distribution(
Automatic Recalc( 1 ),
Continuous Distribution( Column( :height ) ),
Continuous Distribution( Column( :weight ) ),
Local Data Filter(
Add Filter(
columns( :height, :weight ),
Where( :height >= 55 & :height <= 70 ),
Where( :weight >= 64 & :weight <= 160 )
)
)
),
));