mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python$ cd examples/ mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examplnformatics/python/examples$ python day9.py Hello, world mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py bash: ./day9.py: Permission denied mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ls -l day9.py -rw-r--r-- 1 mvoorhie mvoorhie 43 2011-05-04 15:31 day9.py mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ chmod "a+x" day9.py mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ls -l total 92848 -rw-r--r-- 1 mvoorhie mvoorhie 752 2011-05- 03 16:21 aln.py -rw-r--r-- 1 mvoorhie mvoorhie 777 2011-05-03 16:13 aln.py~ -rw-r--r-- 1 mvoorhie mvoorhie 47 2011-04-20 10:11 append.py -rw-r--r-- 1 mvoorhie mvoorhie 274 2011-04-16 17:37 assignment.py -rw-r--r-- 1 mvoorhie mvoorhie 831 2011-04-27 10:30 BatchCluster.py -rw-r--r-- 1 mvoorhie mvoorhie 1018011 2011-05-04 14:39 BinuclearZn.full.cdt -rw-r--r-- 1 mvoorhie mvoorhie 15690 2011-05-04 14:39 BinuclearZn.full.gtr -rw-r--r-- 1 mvoorhie mvoorhie 200 2011-04-19 08:23 builtin_gotcha.py -rw-r--r-- 1 mvoorhie mvoorhie 160 2011-04-16 17:37 calculator.py -rw-r--r-- 1 mvoorhie mvoorhie 5726 2011-05-03 16:09 ClustalTools.py -rw-r--r-- 1 mvoorhie mvoorhie 491 2011-05-03 15:59 clustalw.py -rw-r--r-- 1 mvoorhie mvoorhie 457 2011-05-03 15:58 clustalw.py~ -rw-r--r-- 1 mvoorhie mvoorhie 766 2011-04-25 12:32 cluster_getline.c -rw-r--r-- 1 mvoorhie mvoorhie 317 2011-04-25 12:49 ClusterProtocol.py -rw-r--r-- 1 mvoorhie mvoorhie 213 2011-04-25 12:32 cluster_tokenize.c -rw-r--r-- 1 mvoorhie mvoorhie 38 2011-04-20 10:11 coercion.py -rw-r--r-- 1 mvoorhie mvoorhie 159 2011-04-16 17:37 comparison.py -rw-r--r-- 1 mvoorhie mvoorhie 77 2011-04-16 17:37 comprehension.py -rwxr-xr-x 1 mvoorhie mvoorhie 43 2011-05-04 15:31 day9.py -rw-r--r-- 1 mvoorhie mvoorhie 21 2011-05-04 15:24 day9.py~ -rw-r--r-- 1 mvoorhie mvoorhie 537 2011-04-25 12:49 dehoon.c -rw-r--r-- 1 mvoorhie mvoorhie 109 2011-04-29 13:56 dict.py -rw-r--r-- 1 mvoorhie mvoorhie 88546058 2011-04-27 17:43 distances.cdt -rw-r--r-- 1 mvoorhie mvoorhie 1013 2011-04-27 10:30 DistanceTools.py -rwxr-xr-x 1 mvoorhie mvoorhie 1284 2011-04-27 17:35 distmatrix.py -rw-r--r-- 1 mvoorhie mvoorhie 1046 2011-04-27 17:29 distmatrix.py~ -rw-r--r-- 1 mvoorhie mvoorhie 182 2011-04-27 11:38 dot.emacs -rw-r--r-- 1 mvoorhie mvoorhie 186 2011-04-27 11:36 dot.emacs~ -rw-r--r-- 1 mvoorhie mvoorhie 670 2011-05-02 14:43 dp_fill.py -rw-r--r-- 1 mvoorhie mvoorhie 114 2011-05-02 14:43 dp_init2.py -rw-r--r-- 1 mvoorhie mvoorhie 248 2011-05-02 14:43 dp_init.py -rw-r--r-- 1 mvoorhie mvoorhie 3619 2011-05-02 17:51 dp.py -rw-r--r-- 1 mvoorhie mvoorhie 3685 2011-05-02 14:55 dp.py~ -rw-r--r-- 1 mvoorhie mvoorhie 2918 2011-05-02 18:06 dp.pyc -rw-r--r-- 1 mvoorhie mvoorhie 645 2011-05-02 14:43 dp_traceback.py -rw-r--r-- 1 mvoorhie mvoorhie 512 2011-05-02 14:43 dp_while.py -rw-r--r-- 1 mvoorhie mvoorhie 2930 2011-04-22 15:16 example1.csv -rw-r--r-- 1 mvoorhie mvoorhie 2910 2011-04-22 15:26 example2.csv -rw-r--r-- 1 mvoorhie mvoorhie 83 2011-04-20 10:11 exception.py -rw-r--r-- 1 mvoorhie mvoorhie 77 2011-04-19 08:23 explicit_mean.py -rw-r--r-- 1 mvoorhie mvoorhie 65 2011-04-20 10:11 findfile.py -rw-r--r-- 1 mvoorhie mvoorhie 104 2011-04-16 17:37 function.py -rw-r--r-- 1 mvoorhie mvoorhie 915 2011-04-27 10:31 geneticCode.py -rwxr-xr-x 1 mvoorhie mvoorhie 4559 2011-04-22 11:35 getwhiteboard.py -rw-r--r-- 1 mvoorhie mvoorhie 89 2011-04-22 08:18 getwhiteboard.py~ -rw-r--r-- 1 mvoorhie mvoorhie 712 2011-05-03 16:15 hmmclust.py -rw-r--r-- 1 mvoorhie mvoorhie 18244 2011-05-03 16:00 hmmclust.py~ -rw-r--r-- 1 mvoorhie mvoorhie 19468 2011-05-04 14:28 Hsp82aa.fasta -rw-r--r-- 1 mvoorhie mvoorhie 188 2011-05-02 14:48 identityDict.py -rw-r--r-- 1 mvoorhie mvoorhie 214 2011-04-16 17:37 ifthen.py -rw-r--r-- 1 mvoorhie mvoorhie 774 2011-05-03 16:22 indexing.py -rw-r--r-- 1 mvoorhie mvoorhie 246 2011-04-16 17:37 iteration.py -rw-r--r-- 1 mvoorhie mvoorhie 75 2011-04-20 10:11 listOfLists.py -rw-r--r-- 1 mvoorhie mvoorhie 135 2011-04-22 12:17 list.py -rw-r--r-- 1 mvoorhie mvoorhie 383 2011-04-16 17:37 lists.py -rw-r--r-- 1 mvoorhie mvoorhie 636 2011-05-03 16:12 mainit.py -rw-r--r-- 1 mvoorhie mvoorhie 230 2011-04-19 08:49 math2.py -rw-r--r-- 1 mvoorhie mvoorhie 121 2011-04-16 17:37 math.py -rw-r--r-- 1 mvoorhie mvoorhie 45 2011-04-19 08:23 mean.py -rw-r--r-- 1 mvoorhie mvoorhie 44 2011-05-02 14:43 minmax.py -rw-r--r-- 1 mvoorhie mvoorhie 351 2011-04-16 17:37 nouns.py -rw-r--r-- 1 mvoorhie mvoorhie 9284 2011-04-20 23:20 PairCorrelation.py -rw-r--r-- 1 mvoorhie mvoorhie 225 2011-04-20 21:40 PairCorrelation.py~ -rw-r--r-- 1 mvoorhie mvoorhie 586 2011-04-22 14:48 PairCorrSimple.py -rw-r--r-- 1 mvoorhie mvoorhie 449 2011-04-22 14:43 PairCorrSimple.py~ -rw-r--r-- 1 mvoorhie mvoorhie 704 2011-04-22 12:18 parseTdt.py -rw-r--r-- 1 mvoorhie mvoorhie 286 2011-04-19 08:23 pearson.py -rw-r--r-- 1 mvoorhie mvoorhie 118 2011-04-16 17:37 print.py -rw-r--r-- 1 mvoorhie mvoorhie 202 2011-04-20 10:10 pseudocluster.py -rw-r--r-- 1 mvoorhie mvoorhie 257 2011-04-16 17:37 reload.py -rw-r--r-- 1 mvoorhie mvoorhie 2753 2011-04-22 18:35 reparse.py -rwxr-xr-x 1 mvoorhie mvoorhie 241 2011-04-27 11:53 script.py -rw-r--r-- 1 mvoorhie mvoorhie 82 2011-04-27 11:32 script.py~ -rw-r--r-- 1 mvoorhie mvoorhie 145 2011-04-27 10:31 set.py -rw-r--r-- 1 mvoorhie mvoorhie 198 2011-04-27 10:30 shuffle2.py -rw-r--r-- 1 mvoorhie mvoorhie 513 2011-04-27 10:30 shuffle3.py -rw-r--r-- 1 mvoorhie mvoorhie 305 2011-04-25 12:49 ShuffledClusterProtocol2.py -rw-r--r-- 1 mvoorhie mvoorhie 275 2011-04-25 12:49 ShuffledClusterProtocol.py -rw-r--r-- 1 mvoorhie mvoorhie 432 2011-04-27 10:30 shuffle.py -rw-r--r-- 1 mvoorhie mvoorhie 2399 2011-04-25 14:09 SimpleCdt.py -rw-r--r-- 1 mvoorhie mvoorhie 2399 2011-04-25 13:57 SimpleCdt.py~ -rw-r--r-- 1 mvoorhie mvoorhie 570 2011-04-25 14:39 SimpleCdtSimplified.py -rw-r--r-- 1 mvoorhie mvoorhie 591 2011-04-25 14:38 SimpleCdtSimplified.py~ -rw-r--r-- 1 mvoorhie mvoorhie 2030 2011-04-20 23:37 stats1.py -rw-r--r-- 1 mvoorhie mvoorhie 2028 2011-04-19 10:56 stats1.py~ -rw-r--r-- 1 mvoorhie mvoorhie 140 2011-04-19 17:49 stdev.py -rw-r--r-- 1 mvoorhie mvoorhie 1164 2011-05-03 16:20 stockholm.py -rw-r--r-- 1 mvoorhie mvoorhie 1561 2011-05-03 16:12 stockholm.py~ -rw-r--r-- 1 mvoorhie mvoorhie 236 2011-04-22 12:18 supp2data1.py lrwxrwxrwx 1 mvoorhie mvoorhie 21 2011-04-27 16:38 supp2data.csv -> ../data/supp2data.csv -rw-r--r-- 1 mvoorhie mvoorhie 2630 2011-04-22 12:19 tdtClass.py -rw-r--r-- 1 mvoorhie mvoorhie 2320513 2011-04-25 14:03 test1.cdt -rw-r--r-- 1 mvoorhie mvoorhie 2736813 2011-04-25 14:04 test2.cdt -rw-r--r-- 1 mvoorhie mvoorhie 312 2011-04-27 10:31 uidset.py -rw-r--r-- 1 mvoorhie mvoorhie 61 2011-04-20 14:13 vectorOps2.py -rw-r--r-- 1 mvoorhie mvoorhie 71 2011-04-20 14:13 vectorOps.py -rw-r--r-- 1 mvoorhie mvoorhie 144 2011-04-16 17:37 verbs1.py -rw-r--r-- 1 mvoorhie mvoorhie 739 2011-04-25 12:49 writeCDT.py -rw-r--r-- 1 mvoorhie mvoorhie 365 2011-04-25 12:49 writeTDT.py mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ls -l day9.py -rwxr-xr-x 1 mvoorhie mvoorhie 43 2011-05-04 15:31 day9.py mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ day9.py day9.py: command not found mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py Hello, world mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py Hello, world mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py this is a test Hello, world ['./day9.py', 'this', 'is', 'a', 'test'] mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py this is a test "and so is this" Hello, world ['./day9.py', 'this', 'is', 'a', 'test', 'and so is this'] mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py *.py Hello, world ['./day9.py', 'aln.py', 'append.py', 'assignment.py', 'BatchCluster.py', 'builtin_gotcha.py', 'calculator.py', 'ClustalTools.py', 'clustalw.py', 'ClusterProtocol.py', 'coercion.py', 'comparison.py', 'comprehension.py', 'day9.py', 'dict.py', 'DistanceTools.py', 'distmatrix.py', 'dp_fill.py', 'dp_init2.py', 'dp_init.py', 'dp.py', 'dp_traceback.py', 'dp_while.py', 'exception.py', 'explicit_mean.py', 'findfile.py', 'function.py', 'geneticCode.py', 'getwhiteboard.py', 'hmmclust.py', 'identityDict.py', 'ifthen.py', 'indexing.py', 'iteration.py', 'listOfLists.py', 'list.py', 'lists.py', 'mainit.py', 'math2.py', 'math.py', 'mean.py', 'minmax.py', 'nouns.py', 'PairCorrelation.py', 'PairCorrSimple.py', 'parseTdt.py', 'pearson.py', 'print.py', 'pseudocluster.py', 'reload.py', 'reparse.py', 'script.py', 'set.py', 'shuffle2.py', 'shuffle3.py', 'ShuffledClusterProtocol2.py', 'ShuffledClusterProtocol.py', 'shuffle.py', 'SimpleCdt.py', 'SimpleCdtSimplified.py', 'stats1.py', 'stdev.py', 'stockholm.py', 'supp2data1.py', 'tdtClass.py', 'uidset.py', 'vectorOps2.py', 'vectorOps.py', 'verbs1.py', 'writeCDT.py', 'writeTDT.py'] mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py this is a test Hello, world ./day9.py this is a test mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py this is a test > test.txt ./day9.py this is a test mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ cat test.txt Hello, world mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py this is a test 2> test.txt Hello, world mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ cat test.txt ./day9.py this is a test mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py this is a test > test.txt 2> test.log mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ cat test.txt Hello, world mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ cat test.log ./day9.py this is a test mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ssh ascus Linux ascus 2.6.32-5-amd64 #1 SMP Wed Jan 12 03:40:32 UTC 2011 x86_64 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Wed May 4 07:30:08 2011 from 166.187.47.65 mvoorhie@ascus:~$ screen -l [screen is terminating] mvoorhie@ascus:~$ screen -L [screen is terminating] mvoorhie@ascus:~$ screen [detached from 26904.pts-0.ascus] mvoorhie@ascus:~$ exit logout Connection to ascus closed. mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ssh ascus Linux ascus 2.6.32-5-amd64 #1 SMP Wed Jan 12 03:40:32 UTC 2011 x86_64 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Wed May 4 15:59:00 2011 from udp004457uds.ucsf.edu mvoorhie@ascus:~$ screen -r [screen is terminating] mvoorhie@ascus:~$ logout Connection to ascus closed. mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ./day9.py this is a test 2> log Hello, world ^Cmvoorhie@virgil:~/Projects/Courses/PracticalBinformatics/python/examples$ ./day9.py this is a test 2> log Hello, world ^Z [1]+ Stopped ./day9.py this is a test 2> log mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ bg [1]+ ./day9.py this is a test 2> log & mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ps -ealf | grep day9 0 T mvoorhie 11238 10237 0 80 0 - 1820 signal 16:05 pts/3 00:00:00 python ./day9.py this is a test 0 S mvoorhie 11242 10237 0 80 0 - 831 pipe_w 16:06 pts/3 00:00:00 grep --color=auto day9 [1]+ Stopped ./day9.py this is a test 2> log mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ kill 11242 bash: kill: (11242) - No such process mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ps -ealf | grep day9 0 T mvoorhie 11238 10237 0 80 0 - 1820 signal 16:05 pts/3 00:00:00 python ./day9.py this is a test 0 S mvoorhie 11244 10237 0 80 0 - 831 pipe_w 16:06 pts/3 00:00:00 grep --color=auto day9 mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ps -ealf | grep day9 0 T mvoorhie 11238 10237 0 80 0 - 1820 signal 16:05 pts/3 00:00:00 python ./day9.py this is a test 0 S mvoorhie 11246 10237 0 80 0 - 831 pipe_w 16:06 pts/3 00:00:00 grep --color=auto day9 mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ kill 11238 mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ps -ealf | grep day9 0 T mvoorhie 11238 10237 0 80 0 - 1820 signal 16:05 pts/3 00:00:00 python ./day9.py this is a test 0 S mvoorhie 11248 10237 0 80 0 - 831 pipe_w 16:07 pts/3 00:00:00 grep --color=auto day9 mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ kill -KILL 11238 mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ ps -ealf | grep day9 0 S mvoorhie 11250 10237 0 80 0 - 831 pipe_w 16:07 pts/3 00:00:00 grep --color=auto day9 [1]+ Killed ./day9.py this is a test 2> log mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ man kill mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ echo "hello there" | ./day9.py some arguments Hello, world ./day9.py some arguments input hello there mvoorhie@virgil:~/Projects/Courses/PracticalBioinformatics/python/examples$ python Python 2.6.5 (r265:79063, Apr 16 2010, 13:09:56) [GCC 4.4.3] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import subprocess >>> subprocess.check_call(("./day9.py","here","are","some","arguments")) Hello, world ./day9.py here are some arguments ^CTraceback (most recent call last): File "./day9.py", line 8, in Traceback (most recent call last): for line in sys.stdin: File "", line 1, in KeyboardInterrupt File "/usr/lib/python2.6/subprocess.py", line 493, in check_call retcode = call(*popenargs, **kwargs) File "/usr/lib/python2.6/subprocess.py", line 480, in call return Popen(*popenargs, **kwargs).wait() File "/usr/lib/python2.6/subprocess.py", line 1170, in wait pid, sts = _eintr_retry_call(os.waitpid, self.pid, 0) File "/usr/lib/python2.6/subprocess.py", line 465, in _eintr_retry_call return func(*args) KeyboardInterrupt >>> subprocess.check_call(("./day9.py","here","are","some","arguments")) Hello, world ./day9.py here are some arguments 0 >>> retval = subprocess.check_call(("./day9.py","here","are","some","arguments")) Hello, world ./day9.py here are some arguments >>> retval 0 >>>