covSoanr v.1.1.3
This release includes
Improvement
**1.Readme.md**
- All new features
- Q&A
- Update DB version and program version
- Meta table
**2. Add function to update lineage information**
Run `update-lineage-info` flag, it will download the latest version of lineages from https://github.com/cov-lineages/pango-designation/ and install in `lib/lineage.all.tsv`
sh
example command
path/to/covsonar/sonar.py update-lineage-info
**3.Database**
According to 21, We add the 'submission date' column to the **genome** table and also **prot_view**and **essence** view *(`submission_date TEXT`). Then, now we can use the match command with the `submission_date` flag to define a condition. The submission date will always be included in the output result. for example;
bash
python sonar.py match
--db ../workdir_covsonar/mycacheV1/mydb.new.db \
--date 2021-10-01 \
--submission_date ^2021-10-31 2021-10-20
**4.Improve error message**
According to 22, We update the error message with the accession number.
**5.Update test script**
**6.Parent-Child relationship**
Now we can query all sublineages by using `--with-sublineage` tag along with match command.
sh
We want to get all sublineages of delta variant (B.1.617.2).
This query will return result as ['B.1.617.2', 'AY.1', 'AY.2', ..., , 'AY.129', 'AY.130']
path/to/covsonar/sonar.py match -i S:N501Y --lineage B.1.617.2 --with-sublineage --db mydb > out.csv
We use sublineage information from https://github.com/cov-lineages/pango-designation/ and create a custom script to automatically convert all information to precomputed lineage file (under **lib/lineage.all.tsv**).
New Features
**1.Database upgrade assistant**
In the upcoming future, if we have the new version of the database schema, we can just use this function to upgrade.
bash
python sonar.py db-upgrade --db mydb.db
This function will automatically update the database to the latest version.
bash
Example Output
Warning: Backup db file before upgrading, Press Enter to continue...
press Enter
Current version: 3 Upgrade to: 4
Perform the Upgrade: file: mydb.db
Database now version: 4
Success: Database upgrade was successfully completed
**2.Export DB to VCF file**
covSonar can export accession records in a VCF format using the `var2vcf` command. The output from this feature is a single VCF file that combines all accessions. The output format is in **.gz** form.
sh
Export all accessions in the database.
path/to/covsonar/sonar.py var2vcf --db mydb -o merge.vcf
Just like the option in the match command, we can use --file, --acc and --date to enable specific accession export.
path/to/covsonar/sonar.py var2vcf --db mydb -f acc.10.txt -o merge.vcf
To speed up the query, we can use --cpus tag to aid us.
path/to/covsonar/sonar.py var2vcf --db mydb --date 2021-08-01:2021-08-10 -o merge.vcf --cpus 20
Another solution, we can use --betaV2 tag (x3-5 times faster),
The current version is under development, so if you found any bug please report it to us.
path/to/covsonar/sonar.py var2vcf --db mydb --date 2021-08-01:2021-08-10 -o merge.vcf --cpus 20 --betaV2
Bug fixes
- **16 17 23**
- Minor bug fixes