| 查看: 1150 | 回复: 13 | |||
| 当前主题已经存档。 | |||
| 当前只显示满足指定条件的回帖,点击这里查看本话题的所有回帖 | |||
[交流]
画物理图形使用Origin的一个routine
|
|||
|
我们使用origin的时候,经常要导入数据并画图,很烦。于是我简单的写了个script 文件,画图方便得很。 如果你是高手请不要笑我,尽管这个东西很简单,可是对于很多新手还是很重要的。 因为我无法上传文件,所以贴在下面了。使用者可以直接copy到script窗口中之行,或者存为ogs文件由origin菜单调用。 手边还有一些其他的求积分,插值,平均,等script,如果这个版上喜欢用origin的人多并且对这个有兴趣再传。 如果你觉得对你有帮助,请推荐,谢谢。 plot.ogs #Plot all the data to one graph window and group them #Expert plot, group the file according to the last 3 character of their names #For expample, CMR010.rat, CMR020.rat, CMR030.rat, represent 1, 2, 3 Telsa respectively #Jinbo 2005 %O="(New Graph) (Appending Graph)"; %L="(Standard Plot) (Special Plot)"; if (neworappend==--){neworappend=1;} if (specialornot==--){specialornot=1;} if (%K=="" {%K=*.*;}if (%P=="" {%P=2:4}getn (Graph Type) neworappend:O (File Type) %%K (Plot Type) Specialornot:L (Expert Plot) expert:2s (Variable Range) %%P (Plot Data); if(neworappend==1) {win -t plot line.otp;%M=%H;} if(neworappend==2) {%M=%H;} getfile -m %K; if (expert==0) { if (specialornot==1) { loop(ii,1,count) { getfile -g ii; win -t data; #Let %N hold the worksheet windowns name, such as data1, data2... #%N=%H; open -w %A; #win -r %H %N%H; %N=%H; %Q=%N!wks.cName2$; win -a %M; layer -i %N_%Q; } layer -at; layer -g; } if (specialornot==2) { loop(ii,1,count) { getfile -g ii; win -t data; #Let %N hold the worksheet windowns name, such as data1, data2... #%N=%H; open -w %A; #win -r %H %N%H; %N=%H; %Q=%N!wks.cName2$; wks.col=2; %L=%[%H,>%[%H]-2]; wks.col.label$=%[%L,3].%[%L,>3] T; field=%[%H,>%[%H]-2]; for(;field>17;field-17); win -a %M; layer -i %N_%Q; set %N_%Q -c field; } layer -at; } } if (expert==1) { begin=%[%P,':']; end=%[%P,>':']; loop(ii,1,count) { getfile -g ii; win -t data; open -w %A; %N=%H; %Q=%N!wks.cName2$; field=%[%H,$(begin):$(end)]; for(;field>17;field-17); win -a %M; layer -i %N_%Q; set %N_%Q -c field; } layer -at; } |
» 猜你喜欢
277 数一104,学硕,求调剂
已经有13人回复
一志愿西交机械专硕求调剂
已经有3人回复
求调剂
已经有3人回复
调剂
已经有14人回复
求调剂 材料与工程 324分 专硕
已经有15人回复
材料085601调剂
已经有11人回复
293求调剂
已经有5人回复
化工调剂求导师收留!一志愿失利,踏实肯干,有植物提取科研经历
已经有12人回复
332求调剂
已经有3人回复
083200 305分 求二轮调剂 不接受跨专业
已经有5人回复
steincat
荣誉版主 (知名作家)
天啊,小木虫
- 应助: 2 (幼儿园)
- 贵宾: 4.03
- 金币: 2370.7
- 散金: 105
- 红花: 6
- 帖子: 8498
- 在线: 298.6小时
- 虫号: 73507
- 注册: 2005-06-08
- 性别: GG
- 专业: 能源化工

5楼2006-02-22 11:24:35
3楼2006-02-22 10:37:46
miniearth
荣誉版主 (著名写手)
- 应助: 0 (幼儿园)
- 贵宾: 1.2
- 金币: 2513.2
- 帖子: 2204
- 在线: 116小时
- 虫号: 133961
- 注册: 2005-12-14
- 性别: GG
- 专业: 物理有机化学
4楼2006-02-22 10:45:10
6楼2006-02-22 12:01:38













{%K=*.*;}
回复此楼
