当前位置:网站首页>2021-10-29 [microbiology] qiime2 sample pretreatment form automation script
2021-10-29 [microbiology] qiime2 sample pretreatment form automation script
2022-06-30 07:37:00 【Muyiqing】
Abstract
Some time ago, I studied 16S/ITS Analysis of , Yes qiime2 Have a certain understanding of the analysis process of , There is already a process for analysis , It will be sorted out and released later . Before analysis , The software needs to provide preprocessing files , Include a sample data sheet ( Two terminal sequencing data format ), A sample grouping table . Both of these were generated manually before , There is no way to group tables , The grouping of each project is different , But the sample data table can be automatically generated . Record here .
Tools and methods
Using language :bash
Use command
The first part is to extract the original data from the project data obtained by the supplier . Put it in 01.data Medium standby
for i in */00.RawData/*/*.raw_1.fq.gz;
do
i=${i%.raw_1.fq.gz};
mv {
${i}.raw_1.fq.gz,${i}.raw_2.fq.gz} ./;
done
Next, you need to obtain the complete sample data path through the sample name , And print qiime2 Table format required .
echo -e "id\tforward-absolute-filepath\treverse-absolute-filepath" >> all_sample.txt;
for i in *.raw_1.fq.gz;
do
i=${i%.raw_1.fq.gz};
echo -e "${i}\t`pwd`/${i}.raw_1.fq.gz\t`pwd`/${i}.raw_2.fq.gz" >> all_sample.txt;
done
Command Introduction
echo -e “” : Identify and print the separator inside the double quotation marks , This ensures that the output format is correct ;pwd : stay echo Execute the path acquisition command in , Absolute path of supplementary samples ;
">> " : Overwrite input into document , If it is a single greater than sign, enter , Previous documents will be cleared , There is only the last line in the final document .
Result display

summary
In fact, it is not difficult to manually operate the document , use excel Can also do . But considering that qiime2 Absolute path required , There is some trouble with every modification , Therefore, this part is optimized . If you have better suggestions , Welcome to discuss , Or add me VX:bbplayer2021 Invite in .
边栏推荐
- Shell command, how much do you know?
- Thread pool - C language
- Cadence physical library lef file syntax learning [continuous update]
- String application -- string violent matching (implemented in C language)
- Analysys analysis: online audio content consumption market analysis 2022
- Common sorting methods
- right four steps of SEIF SLAM
- Research Report on search business value in the era of big search in 2022
- 期末複習-PHP學習筆記6-字符串處理
- Cubemx completes STM32F103 dual serial port 485 transceiver transmission
猜你喜欢

Test enumeration types with STM32 platform running RT thread

03 - programming framework: Division of application layer, middle layer and driver layer in bare metal programming

视频播放器(一):流程

Efga design open source framework openlane series (I) development environment construction

2021 China Enterprise Cloud index insight Report

期末复习-PHP学习笔记8-mysql数据库

Basic knowledge points

Deloitte: investment management industry outlook in 2022

Virtual machine VMware: due to vcruntime140 not found_ 1.dll, unable to continue code execution

Examen final - notes d'apprentissage PHP 3 - Déclaration de contrôle du processus PHP
随机推荐
期末复习-PHP学习笔记1
Efga design open source framework openlane series (I) development environment construction
期末复习-PHP学习笔记2-PHP语言基础
Cadence innovus physical implementation series (I) Lab 1 preliminary innovus
Is it safe to open a stock account by mobile phone? What do I need to prepare for opening an account?
期末复习-PHP学习笔记8-mysql数据库
C language - student achievement management system
Network security and data in 2021: collection of new compliance review articles (215 pages)
Implementation of double linked list in C language
Proteus catalog component names and Chinese English cross reference
Examen final - notes d'apprentissage PHP 3 - Déclaration de contrôle du processus PHP
Final review -php learning notes 7-php and web page interaction
记录开发过程中无法使用管理员身份修改系统文件问题
Pool de Threads - langage C
Tencent and Fudan University "2021-2022 yuan universe report" with 102 yuan universe collections
Assembly learning register
STM32 infrared communication
Network security - packet capture and IP packet header analysis
DXP shortcut key
Implementation of binary search in C language