efetch -db nucleotide -id KM233090 -format fasta > KM233090.fa
efetch -db nucleotide -id 667853062 -format fasta > 667853062.fa
efetch -db nucleotide -id KM233090,KM233066,KM233113.1 -format fasta > multi.fa
wc -l multi.fa
cat multi.fa | grep ">" | wc -l
cat multi.fa | grep ">"
efetch -db nucleotide -id KM233090,KM233066,KM233113.1 -format fasta -seq_start 1 -seq_stop 10 > multi.fa
esearch -db nucleotide -query PRJNA257197 | efetch -db nucleotide -format fasta -seq_start 1 -seq_stop 10 > starts.fa
bash get_seq.sh > starts.fa
bash get_seq.sh 1 10 > starts.fa
cat starts.fa | grep ">" -A 1 | grep -v ">" | grep -v "-"
#!/bin/sh## 从所有的序列中把核苷酸子序列抓取出来。# 存放在PRJNA257197 这个项目(project)里。## 预期有start和stop这两个参数。# 这个设置使脚本停止在错误和未定义变量上。set -ue# 通过Entrez Direct访问NCBI。esearch -db nucleotide -query PRJNA257197 | efetch -db nucleotide -format fasta -seq_start $1 -seq_stop $2
# 从所有的序列中把核苷酸子序列抓取出来。# 存放在PRJNA257197 这个项目(project)里。# 预期有start和stop这两个参数。# 这个设置使脚本停止在错误和未定义变量上。set -ue
function esearch_ebola() { # 搜索ebola(埃博拉)的核苷酸序列。
esearch -db nucleotide -query PRJNA257197
}
function efetch_limits() { # 你可以把变量表示什么变得更明确。
# 对于更为复杂的命令,这应该会帮助。
START=$1
END=$2
# 运行efetch.
efetch -db nucleotide -format fasta -seq_start $START -seq_stop $END}# 把两个命令链起来获取数据。# 请留意着两个参数是如何传递到函数中的。esearch_ebola | efetch_limits $1 $2
python -c 'print "Hello World"'
python -c 'print ord("A")'
python -c "print chr(65)"
python -c 'print ord("I") - 33'
python -c 'print ord("I") - 64'
python -c 'print chr(40 + 33)'
python -c 'print chr(40 + 64)'
curl -O http://www.personal.psu.edu/iua1/courses/files/2014/illumina-data.fq.gz
time gzcat illumina-data.fq.gz > tmp
gunzip -c illumina-data.fq.gz > illumina-data.fq
time cat illumina-data.fq > tmp
gzcat illumina-data.fq.gz | head -4
zcat illumina-data.fq.gz | head -4
fastq-dump --split-files SRR1553605
cat SRR1553605_1.fastq | head -4
gzcat illumina-data.fq.gz | head -10000 | grep '###' | wc -lcat SRR1553605_1.fastq | head -10000 | grep '###' | wc -l
gzcat illumina-data.fq.gz | head -10000 | grep 'ATG' --color=always | head
gzcat illumina-data.fq.gz | head -10000 | grep 'TATA' --color=always | head
gzcat illumina-data.fq.gz | head -10000 | grep 'GATCGGA' --color=always | head
翻译:生物女博士
注:本系列课程翻译已获得原作者授权。
欢迎关注我们