上一页 1 ··· 194 195 196 197 198 199 200 201 202 ··· 408 下一页
摘要: 001、 >>> import time ## 导入time包 >>> start = time.time() ## 记录程序开始时间 >>> print("xxxxx") xxxxx >>> end = time.time() ## 记录程序结束时间 >>> print("elapsed:", e 阅读全文
posted @ 2022-08-11 20:48 小鲨鱼2018 阅读(181) 评论(0) 推荐(0)
摘要: 001、保存为字典 (base) root@PC1:/home/test2# ls a.fastq test.py (base) root@PC1:/home/test2# cat a.fastq ## 测试fastq文件 @SRR1596091.1 HISEQ:62:C35RDACXX:2:110 阅读全文
posted @ 2022-08-11 20:33 小鲨鱼2018 阅读(111) 评论(0) 推荐(0)
摘要: 001、 (base) root@PC1:/home/test2# ls a.fasta test.py (base) root@PC1:/home/test2# cat a.fasta ## 测试fasta文件 >gene1 myc AGCTGCCTAAGC GGCATAGCTAATCG >gen 阅读全文
posted @ 2022-08-11 19:46 小鲨鱼2018 阅读(262) 评论(0) 推荐(0)
摘要: 001、 >>> str1 = "abeababxxxaacdx" >>> dict1 = {} >>> for i in str1: ## 利用循环结构,将字符串中每个字符出现的次数储存在字典中 ... dict1[i] = str1.count(i) ... >>> for i in dict1 阅读全文
posted @ 2022-08-11 19:39 小鲨鱼2018 阅读(1558) 评论(0) 推荐(0)
摘要: 001、 >>> str1 = "abcdabaewr" ## 测试字符串 >>> import re >>> len(re.findall("a", str1)) ## 统计a出现的次数 3 >>> len(re.findall("b", str1)) ## 统计b出现的次数 2 >>> len( 阅读全文
posted @ 2022-08-11 19:35 小鲨鱼2018 阅读(379) 评论(0) 推荐(0)
摘要: 001、 (base) root@PC1:/home/test2# ls a.fasta test.py (base) root@PC1:/home/test2# cat a.fasta ## 测试fasta文件 >gene1 myc AGCTGCCTAAGC GGCATAGCTAATCG >gen 阅读全文
posted @ 2022-08-11 19:24 小鲨鱼2018 阅读(155) 评论(0) 推荐(0)
摘要: 001、 (base) root@PC1:/home/test2# ls a.fasta test.py (base) root@PC1:/home/test2# cat a.fasta ## 测试fasta文件 >gene1 myc AGCTGCCTAAGC GGCATAGCTAATCG >gen 阅读全文
posted @ 2022-08-11 19:07 小鲨鱼2018 阅读(127) 评论(0) 推荐(0)
摘要: 001、 (base) root@PC1:/home/test2# ls collective.txt (base) root@PC1:/home/test2# cat collective.txt ## 测试文件, 删除每个字符中/前的所有内容 test1/1.txt test1/2.txt te 阅读全文
posted @ 2022-08-11 16:16 小鲨鱼2018 阅读(985) 评论(0) 推荐(0)
摘要: 001、方式1 (base) root@PC1:/home/test2# ls test1 test2 test3 (base) root@PC1:/home/test2# tree . ├── test1 │ ├── 1.txt │ ├── 2.txt │ └── 3.txt ├── test2 阅读全文
posted @ 2022-08-11 15:59 小鲨鱼2018 阅读(5538) 评论(0) 推荐(0)
摘要: 001、 (base) root@PC1:/home/test2# ls ## 当前目录下三个文件夹 test1 test2 test3 (base) root@PC1:/home/test2# tree ## 使用tree命令查看 . ├── test1 │ ├── 1.txt │ ├── 2.t 阅读全文
posted @ 2022-08-11 15:48 小鲨鱼2018 阅读(1532) 评论(0) 推荐(0)
上一页 1 ··· 194 195 196 197 198 199 200 201 202 ··· 408 下一页