From 74969b07958e3aef3055c38decb31c5314fe9a9b Mon Sep 17 00:00:00 2001 From: Albert Cheng Date: Thu, 18 Nov 2010 02:28:05 -0500 Subject: [PATCH] third commit --- BedSeqUtil.py | 77 ------------------- TopGroupOutlierCount.py | 26 +++++++ TopGroupsFromAtrCdt.py | 26 +++++++ absdirname.py | 31 +++++++- abspath.py | 26 +++++++ ...eTranscriptsFromMAFStitchedContigBedSeq.py | 28 ++++++- convertSeqTable2MultiAlignmentFasta.py | 0 convertTab2Pssm.py | 26 ++++++- csfas2fas.py | 26 +++++++ ebed2GenePred.py | 28 ++++++- extractBlockFromMemeOutput.py | 28 ++++++- fasta2seq.py | 29 ++++++- genePred2RefGene.py | 26 +++++++ guessFastQType.py | 28 ++++++- makeTranscriptExonStringFromGff.py | 26 ++++++- mapFeatureViaRgAnnotationToGenomicBed.py | 26 +++++++ mkdir.py | 28 ++++++- motifAlignment2TOMTOM2.py | 26 +++++++ removeInvalidCharactersFromSeq.py | 28 ++++++- solidsrf2csfastq.py | 2 - splitFasReads.py | 28 ++++++- stitchMAFIntoContigBedSeq.py | 28 ++++++- truncateFasReads.py | 28 ++++++- 23 files changed, 533 insertions(+), 92 deletions(-) delete mode 100755 BedSeqUtil.py delete mode 100755 convertSeqTable2MultiAlignmentFasta.py delete mode 100755 solidsrf2csfastq.py diff --git a/BedSeqUtil.py b/BedSeqUtil.py deleted file mode 100755 index 227119b..0000000 --- a/BedSeqUtil.py +++ /dev/null @@ -1,77 +0,0 @@ -#!/usr/bin/python -''' - - For piping between bedSeq program from Python scripts - -''' - -def toStrArray(L): - L2=[] - for x in L: - L2.append(str(x)) - - return L2 - - -from subprocess import * - -from sys import * - -defaultBedSeqCommand=["bedSeq","","/dev/stdin","bed"] - -class BedSeqClient: - child_stdin=None - child_stderr=None - child_stdout=None - def __init__(self,seqDir,bedType,extraParams=None,bedSeqProgramName='bedSeq',inputFileName='/dev/stdin'): - param=[bedSeqProgramName,seqDir,inputFileName,bedType,"--print-OK"] - if extraParams: - param.extend(extraParams) - - p=Popen(" ".join(param), shell=True, stdin=PIPE, stdout=PIPE, stderr=PIPE, close_fds=True) - (self.child_stdin,self.child_stdout,self.child_stderr)=(p.stdin,p.stdout,p.stderr) - - def getBedSeq(self,bedentry): - if type(bedentry).__name__=="list": - bedentry="\t".join(toStrArray(bedentry)) - - print >> self.child_stdin,bedentry - - error=self.child_stderr.readline().strip() - - if error=="OK": - result=self.child_stdout.readline().strip() - return result - else: - raise ValueError - - def getSeq(self,bedentry): - result=self.getBedSeq(bedentry) - fields=result.split("\t") - return fields[-1] - - def close(self): - self.child_stdin.close() - self.child_stdout.close() - self.child_stderr.close() - - - -if __name__=='__main__': - programName=argv[0] - args=argv[1:] - try: - seqDir,=args - except: - print >> stderr,programName,"seqDir","> ofile" - exit() - - tries=["chr10\t100225000\t100225200","chr","chr12\t11125235\t11125256"] - bedSeqClient=BedSeqClient(seqDir,"bed") - for tri in tries: - try: - print >> stdout,bedSeqClient.getBedSeq(tri) - except: - pass - bedSeqClient.close() - \ No newline at end of file diff --git a/TopGroupOutlierCount.py b/TopGroupOutlierCount.py index e3e3d38..4396743 100755 --- a/TopGroupOutlierCount.py +++ b/TopGroupOutlierCount.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * diff --git a/TopGroupsFromAtrCdt.py b/TopGroupsFromAtrCdt.py index 14ff98f..0fc70dc 100755 --- a/TopGroupsFromAtrCdt.py +++ b/TopGroupsFromAtrCdt.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + ''' ATR NODE1X ARRY29X ARRY7X 0.515771470649 NODE2X NODE1X ARRY6X 0.467319235028 diff --git a/absdirname.py b/absdirname.py index baa1b71..d556c7e 100755 --- a/absdirname.py +++ b/absdirname.py @@ -1,8 +1,37 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + + from sys import * from os.path import * + + def getDirName(relPath): absPath=abspath(relPath) dirName=dirname(absPath) @@ -23,4 +52,4 @@ def getDirName(relPath): dirName=getDirName(pathName) - print >> stdout,dirName \ No newline at end of file + print >> stdout,dirName diff --git a/abspath.py b/abspath.py index f06e8af..0f47418 100755 --- a/abspath.py +++ b/abspath.py @@ -1,5 +1,31 @@ #!/usr/bin/env python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * from os.path import * from os import * diff --git a/assembleTranscriptsFromMAFStitchedContigBedSeq.py b/assembleTranscriptsFromMAFStitchedContigBedSeq.py index 12a6245..64d960f 100755 --- a/assembleTranscriptsFromMAFStitchedContigBedSeq.py +++ b/assembleTranscriptsFromMAFStitchedContigBedSeq.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * from BedSeqUtil import * @@ -347,4 +373,4 @@ def reverse_complement(S): print >> stderr,"\t"+error refGenomeBedSeqClient.close() - \ No newline at end of file + diff --git a/convertSeqTable2MultiAlignmentFasta.py b/convertSeqTable2MultiAlignmentFasta.py deleted file mode 100755 index e69de29..0000000 diff --git a/convertTab2Pssm.py b/convertTab2Pssm.py index 64815ea..17a7d19 100755 --- a/convertTab2Pssm.py +++ b/convertTab2Pssm.py @@ -1,7 +1,31 @@ #!/usr/bin/python #convertTab2Pssm.py +''' + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' from sys import * @@ -92,4 +116,4 @@ def toPSSM(M): for sPSSMrow in sPSSM: print >> stdout," ".join(sPSSMrow) - \ No newline at end of file + diff --git a/csfas2fas.py b/csfas2fas.py index 0b7658b..4d1e17a 100755 --- a/csfas2fas.py +++ b/csfas2fas.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + #BELOW IS COPIED FROM AGAPYTHON Util/Dibase.py ### ############### ### diff --git a/ebed2GenePred.py b/ebed2GenePred.py index 1cefbc9..24e93cf 100755 --- a/ebed2GenePred.py +++ b/ebed2GenePred.py @@ -1,6 +1,32 @@ #!/usr/bin/python ''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + +''' extended bed (ebed) 1) chrom @@ -358,4 +384,4 @@ def ebedToebedSeqConvert(filename,eebedseqfilename,options): # exit() - \ No newline at end of file + diff --git a/extractBlockFromMemeOutput.py b/extractBlockFromMemeOutput.py index 543837f..f7b7008 100755 --- a/extractBlockFromMemeOutput.py +++ b/extractBlockFromMemeOutput.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * #extract block from meme.txt @@ -52,4 +78,4 @@ exit() -print >> stderr,":total blocks:",nblocks \ No newline at end of file +print >> stderr,":total blocks:",nblocks diff --git a/fasta2seq.py b/fasta2seq.py index 856bd83..0aca7fc 100755 --- a/fasta2seq.py +++ b/fasta2seq.py @@ -1,5 +1,32 @@ #!/usr/bin/python + +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * def output(seqname,seq): @@ -32,4 +59,4 @@ def output(seqname,seq): fil.close() - output(seqname,seq) \ No newline at end of file + output(seqname,seq) diff --git a/genePred2RefGene.py b/genePred2RefGene.py index de92a6a..ed8a252 100755 --- a/genePred2RefGene.py +++ b/genePred2RefGene.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + #Usage: convertToRefGene.py genScan.txt startpos=0 import sys; diff --git a/guessFastQType.py b/guessFastQType.py index 5089457..b8a7a4d 100755 --- a/guessFastQType.py +++ b/guessFastQType.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * if __name__=='__main__': @@ -91,4 +117,4 @@ print >> stderr,"most likely illumina/solexa-1.3+, although solexa or sanger format cannot be ruled out" print >> stdout,"\t".join([filename,"ILLUMINASOLEXA1.3+|SOLEXA|SANGER",exampleLine,str(minSeqL),str(maxSeqL)]) #filename+"\tILLUMINASOLEXA1.3+|SOLEXA|SANGER\t"+exampleLine+"\t"+"minLen=",minSeqL,";maxLen=",maxSeqL - \ No newline at end of file + diff --git a/makeTranscriptExonStringFromGff.py b/makeTranscriptExonStringFromGff.py index 520efe1..33c957a 100755 --- a/makeTranscriptExonStringFromGff.py +++ b/makeTranscriptExonStringFromGff.py @@ -1,6 +1,30 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' ''' chr1 . exon 3204563 3207049 . - . ID=Xkr4@EXON5;Parent=Xkr4.aSep07 @@ -107,4 +131,4 @@ def printUsageAndExit(programName): print >> stdout,transcriptID+"\t"+"_".join(exonNameSplits) - \ No newline at end of file + diff --git a/mapFeatureViaRgAnnotationToGenomicBed.py b/mapFeatureViaRgAnnotationToGenomicBed.py index 6d90ffd..8f7e804 100755 --- a/mapFeatureViaRgAnnotationToGenomicBed.py +++ b/mapFeatureViaRgAnnotationToGenomicBed.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * from getopt import getopt from albertcommon import * diff --git a/mkdir.py b/mkdir.py index 8505a70..6c1c8e1 100755 --- a/mkdir.py +++ b/mkdir.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * from os import * from os.path import * @@ -17,4 +43,4 @@ makedirs(pathName) - \ No newline at end of file + diff --git a/motifAlignment2TOMTOM2.py b/motifAlignment2TOMTOM2.py index 5352d5c..1bdeae9 100755 --- a/motifAlignment2TOMTOM2.py +++ b/motifAlignment2TOMTOM2.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * diff --git a/removeInvalidCharactersFromSeq.py b/removeInvalidCharactersFromSeq.py index 4aeb946..8c66fd1 100755 --- a/removeInvalidCharactersFromSeq.py +++ b/removeInvalidCharactersFromSeq.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + #removeInvalidCharactersFromSeq.py from sys import * @@ -64,4 +90,4 @@ print >> stdout,"\t".join(fields) - fil.close() \ No newline at end of file + fil.close() diff --git a/solidsrf2csfastq.py b/solidsrf2csfastq.py deleted file mode 100755 index 8d5063a..0000000 --- a/solidsrf2csfastq.py +++ /dev/null @@ -1,2 +0,0 @@ -#!/usr/bin/python - diff --git a/splitFasReads.py b/splitFasReads.py index 34191b6..eaa7c65 100755 --- a/splitFasReads.py +++ b/splitFasReads.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + #split read into x bp, discarding + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + from sys import * @@ -136,4 +162,4 @@ def fillStringUpToWith(S,length,withChr): - \ No newline at end of file + diff --git a/truncateFasReads.py b/truncateFasReads.py index 4959aa5..d418fc4 100755 --- a/truncateFasReads.py +++ b/truncateFasReads.py @@ -1,5 +1,31 @@ #!/usr/bin/python +''' + + + +Copyright 2010 Wu Albert Cheng + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +''' + #split read into x bp, discarding