Moderator: Matt Shirley

gravatar for Matt Shirley
Matt Shirley7.1k
Reputation:
7,110
Status:
Trusted
Location:
Cambridge, MA
Website:
http://mattshirley.com/
Twitter:
mdshw5
Scholar ID:
Google Scholar Page
Last seen:
3 hours ago
Joined:
5 years, 11 months ago
Email:
m*****@gmail.com

Posts by Matt Shirley

<prev • 641 results • page 1 of 65 • next >
2
votes
2
answers
136
views
2
answers
Comment: C: Modifying Fasta file header
... Apparently biopython uses the strict definition (if FASTA has any) of the ID as everything before the first space. See https://www.biostars.org/p/18987/ To get the whole header you want `SeqRecord.description` not `SeqRecord.id` ...
written 10 days ago by Matt Shirley7.1k
1
vote
2
answers
136
views
2
answers
Comment: C: Modifying Fasta file header
... Most methods that access FASTA entries using the offsets stored in a *.fai file will truncate the header name at the first whitespace. However, Bio.SeqIO does not use this scheme. Both samtools and pyfaidx do, but there's a method in pyfaidx: `FastaRecord.longname` will recover the entire header nam ...
written 11 days ago by Matt Shirley7.1k
0
votes
2
answers
136
views
2
answers
Comment: C: Modifying Fasta file header
... It might be helpful to know why you want to modify your headers in this fashion and what some of your other headers look like. ...
written 11 days ago by Matt Shirley7.1k
1
vote
2
answers
106
views
2
answers
Comment: C: Adding Fasta unique identifiers
... awk '/^>/ {printf(">%d %s\n",++N,substr($0,2));next;} {print;}' input.fa > output.fa ...
written 11 days ago by Matt Shirley7.1k
0
votes
3
answers
114
views
3
answers
Answer: A: Delete fasta sequence with a pattern "unassigned peptidases"
... $ pip install pyfaidx $ faidx sequences.fa --regex '.*unassigned peptidases.*' --invert-match > no_peptidases.fa You can find more usage for `faidx` here: https://github.com/mdshw5/pyfaidx#faidx ...
written 11 days ago by Matt Shirley7.1k
2
votes
3
answers
190
views
3
answers
Answer: A: Parsing FASTA file using class in Python
... If you want a fasta file to act like a sequence dictionary, just use [pyfaidx](https://github.com/mdshw5/pyfaidx): import pyfaidx fa = pyfaidx.Fasta("sample.fa") for key in fa: print(key) # sequence name print(fa[key]) # sequence object You'll be using an efficient method t ...
written 19 days ago by Matt Shirley7.1k
5
votes
1
answer
278
views
1
answers
Comment: C: Can Biostars use question template like Github issue/PR?
... I really like this idea, though care needs to be taken not to punish users if they can't clearly describe the problem, and make sure "I haven't tried anything" is sometimes appropriate when we're learning new subject matter. ...
written 25 days ago by Matt Shirley7.1k
2
votes
8
answers
436
views
8
answers
Answer: A: fasta seq header
... $ pip install pyfaidx $ faidx -e "lambda x: x.split('|')[0]" genes.fa >gene_1 ATGCGTCGACGTCGTACGGGTTTT CGTACGGGTTATGCGTCGACGTC GTACGGGTTTT ... ...
written 25 days ago by Matt Shirley7.1k
0
votes
0
answers
191
views
0
answers
Comment: C: GC Content of Fasta file --- Python Help
... No, apparently I'm blind :) ...
written 28 days ago by Matt Shirley7.1k
1
vote
0
answers
191
views
0
answers
Comment: C: GC Content of Fasta file --- Python Help
... As an aside, I think this is one of the problems with testing-as-an-interview-screen since the OP could have great biology or reasoning skills but just doesn't nail this specific problem. It's obvious that there's lots of logic in this python function, also understanding of the problem, and an infor ...
written 29 days ago by Matt Shirley7.1k

Latest awards to Matt Shirley

Teacher 12 days ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Popular Question 16 days ago, created a question with more than 1,000 views. For Comments Left Inappropriately As Answers To A Question
Teacher 18 days ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Appreciated 25 days ago, created a post with more than 5 votes. For A: Ways To Detect Bias In Dna Sampling For Genomic Sequencing
Commentator 25 days ago, created a comment with at least 3 up-votes. For C: What Does 2X250Bp Buy Us?
Popular Question 9 weeks ago, created a question with more than 1,000 views. For Troubling Trends In Scientific Software Use
Good Answer 9 weeks ago, created an answer that was upvoted at least 5 times. For A: How Can I Do Principal Components Analysis ?
Scholar 10 weeks ago, created an answer that has been accepted. For A: How to use pygr? worldbase doesn't return anything
Appreciated 3 months ago, created a post with more than 5 votes. For A: Ways To Detect Bias In Dna Sampling For Genomic Sequencing
Teacher 3 months ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Teacher 4 months ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Commentator 4 months ago, created a comment with at least 3 up-votes. For C: What Does 2X250Bp Buy Us?
Appreciated 5 months ago, created a post with more than 5 votes. For A: Ways To Detect Bias In Dna Sampling For Genomic Sequencing
Teacher 5 months ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Good Answer 6 months ago, created an answer that was upvoted at least 5 times. For A: Generate Vcf.Gz File And Its Index File Vcf.Gz.Tbi
Teacher 6 months ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Teacher 7 months ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Scholar 8 months ago, created an answer that has been accepted. For A: How to use pygr? worldbase doesn't return anything
Teacher 9 months ago, created an answer with at least 3 up-votes. For A: What Does 2X250Bp Buy Us?
Appreciated 10 months ago, created a post with more than 5 votes. For A: Ways To Detect Bias In Dna Sampling For Genomic Sequencing
Teacher 10 months ago, created an answer with at least 3 up-votes. For A: How To Select Only One Human Genome Build (Hg19) From The Encode Project'S Data
Good Answer 10 months ago, created an answer that was upvoted at least 5 times. For A: Not having root access sucks; installing software without root privileges
Commentator 11 months ago, created a comment with at least 3 up-votes. For C: What Does 2X250Bp Buy Us?
Teacher 11 months ago, created an answer with at least 3 up-votes. For A: How To Select Only One Human Genome Build (Hg19) From The Encode Project'S Data
Popular Question 11 months ago, created a question with more than 1,000 views. For Troubling Trends In Scientific Software Use

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 836 users visited in the last hour