如何通過腳本將查詢的數據表保存到指定的文件夾?</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" );