如何通过脚本将查询的数据表保存到指定的文件夹?</CODE></PRE><P>你好! 这里有人知道如何通过jmp脚本将查询到的数据表保存到指定的文件夹吗? 似乎找不到正确的方法来做... 提前致谢!</P><P>这是我的示例脚本:</P><PRE><CODE class=" language-jsl">Data Table( "name of data table" );
//save raw data table to a folder
dt = current data table ();
filepath = "C:\Users\folder path";
dt<< save(filepath || "name of data table.jmp");
数据表脚本编写回复:如何通过脚本将查询的数据表保存到指定的文件夹?我怀疑问题是您的文件路径和“数据表的名称.jmp”之间缺少“ /”。下面是一个工作脚本,
Names Default To Here( 1 );
Open( "$SAMPLE_DATA\big class.jmp" );
dt = Data Table( "big class" );
filepath = "$TEMP";
Wait( 5 ); // placed for the example so the table will be visible
dt << save( filepath || "\" || "mytable.jmp" );
Close( dt, nosave );
Wait( 5 ); // placed so for the example one can see the table is closed
Open( filepath || "\" || "mytable.jmp" );