你好,我正在 jmp 中构建 1Click,当我创建一个双变量石墨时,它会创建类似这样的框

我设法删除它们(折叠),但问题是,因为它是 1Click,当我进行诸如过滤之类的更改时它会再次返回,因为在双变量图中设置为:自动重新计算(1)
所以我想从调度中删除它,这样每次重新计算时它都会删除它,它可以与图片框一起使用,但不能与轮廓框一起使用,因为它看起来像是在要求框命名而不是轮廓框编号,有什么想法吗

我在 JMP 18 和 JMP 14 下运行了您的代码。我看到图例在 14 下展开,但在 18 下运行时没有错误。显然建议升级。
您可以尝试在每次从复选框中调整图表时完全删除它
谢谢,这可行,但是...也许您可以提供以下帮助:
我有这段代码,当我使用图例按钮时,所有功能都正常工作,但是当我开始使用过滤器时,它会打开一堆边框。我相信它来自“自动重新计算”,并且由于某种原因,边框卡在内存中...
知道如何解决这个问题吗?
//obj << show tree structure
//Report( obj )[Outline Box( 1)] << Delete;
//Begin Script;
CreateTrendPlot = Function( {},
// Create and return the trend plot with legend
obj = Bivariate(
Y( :height ),
X( :weight ),
Automatic Recalc( 1 ),
Group By( :sex ),
Fit Spline( 0.1, standardized ),
SendToReport(
Dispatch( {}, "Bivar Plot", FrameBox,
{Row Legend(
age,
Color( 0 ),
Color Theme( "" ),
Marker( 0 ),
Marker Theme( "" ),
Continuous Scale( 0 ),
Reverse Scale( 0 ),
Excluded Rows( 0 )
), Row Legend(
age,
Color( 0 ),
Color Theme( "" ),
Marker( 0 ),
Marker Theme( "" ),
Continuous Scale( 0 ),
Reverse Scale( 0 ),
Excluded Rows( 0 )
)}
),
Dispatch( {}, "", Picture Box( 3 ), {Visibility( "Collapse" )} ),
Dispatch( {}, "", Picture Box( 2 ), {Visibility( "Collapse" )} )
)
)
);
CreateVarPlot = Function( {},
obj2 = Variability Chart(
Y( :height ),
X( :age, :sex ),
Connect Cell Means( 1 ),
Show Group Means( 1 ),
Show Grand Mean( 1 ),
Show Grand Median( 1 ),
Std Dev Chart( 0 ),
Points Jittered( 1 ),
Show Box Plots( 1 ),
Mean Diamonds( 1 ),
SendToReport(
Dispatch( {}, "2", ScaleBox,
{Min( 5000 ), Max( 2000 ), Inc( 100 ), Minor Ticks( 1 ),
Add Ref Line( 0, "Dotted", "Medium Light Gray", "", 1 ),
Add Ref Line( 3200, "Solid", "Black", "TGT", 4 ), Add Ref Line(
4200, "Dashed", "Medium Dark Red", "UCL", 4
), Add Ref Line( 2200, "Dashed", "Medium Dark Red", "LCL", 4 )}
),
Dispatch( {""}, "", NomAxisBox, {Rotated Tick Labels( 0 )} )
)
)
);
// Open Data Table: Big Class.jmp
// → Data Table( "Big Class" )
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
color = {"age", "sex"};
marks = {"age", "sex"};
boxPlot = {"age", "sex", "name"};
// Initial nlevels is the number of levels of 'age', as it is the first by-group used.
cur_col = "age";
cur_mar = "age";
// Creating the legend. For each selection, the previous spline fits are removed, then
// new ones are generated.
color_legend = Panel Box( "Choose Color",
legend1 = Radio Box(
color,
<<SET function=""></SET>
<DIV> </DIV>
<P> </P>For Each() 函数是在 JMP 16 中引入的。
这是 JSL 的修改版本,它删除了 For Each() 并将其替换为 For() 循环。我在 JMP 14 中对其进行了测试,并且它按预期工作。
Names Default To Here( 1 );
dt =
// Open Data Table: Big Class.jmp
// → Data Table( "Big Class" )
Open( "$SAMPLE_DATA/Big Class.jmp" );
biv = Bivariate(
Y( :height ),
X( :weight ),
Fit Spline( 10000, {Line Color( {212, 73, 88} )} ),
Fit Spline( 1, {Line Color( {61, 174, 70} )} ),
Automatic Recalc( 1 )
);
Report( biv )[framebox( 1 )] <<
add graphics script(
oboxes = biv << xpath( "//OutlineBox" );
For( i = 1, i <= N Items( oboxes ), i++,
box = oboxes[i];
If( Contains( box << get title, "Smoothing Spline" ),
box << visibility( "collapse" )
);
);
);你好,我正在使用 JMP14
在日志中这是我看到的
名称未解析:在访问或评估“For Each”,For Each(
{盒子},
oboxes,
如果(包含(框<<获取标题,“平滑样条线”),
框<<可见性(“折叠”)
)
)/*###*/
您使用的是哪个版本的 JMP?
运行代码时,它会产生以下输出

每当输出发生变化时,都会执行添加图形脚本。我的解释是,您需要关闭与样条拟合相关的轮廓框。这就是代码的作用。即使应用了过滤器等,轮廓框仍保持折叠状态。
您在日志中收到任何错误消息吗?
尝试一下这样的方法。它使用添加图形脚本来处理轮廓框的折叠
Names Default To Here( 1 );
dt =
// Open Data Table: Big Class.jmp
// → Data Table( "Big Class" )
Open( "$SAMPLE_DATA/Big Class.jmp" );
biv = Bivariate(
Y( :height ),
X( :weight ),
Fit Spline( 10000, {Line Color( {212, 73, 88} )} ),
Fit Spline( 1, {Line Color( {61, 174, 70} )} ),
Automatic Recalc( 1 )
);
Report( biv )[framebox( 1 )] << add graphics script(
oboxes = biv << xpath( "//OutlineBox" );
For Each( {box}, oboxes,
If( Contains( box << get title, "Smoothing Spline" ),
box << visibility( "collapse" )
)
);
);删除/隐藏 OutlineBox 的一个快速而又简单的方法:折叠它们*)并删除标题。
如果你直接删除标题——而不是先折叠它——你可能已经猜到了:它只会删除标题:)
*)要一次折叠所有 OutlineBox,请按住 CTRL 键并单击灰色三角形。