added beginning of program, md.pdb as toy example and README
parent
220ba06a41
commit
88d52b8e8f
|
|
@ -0,0 +1,22 @@
|
|||
Make sure your current directory is projet_court_nz
|
||||
|
||||
Environment
|
||||
|
||||
1 - Recreate the conda environment with the config_projet.yml file avaible in the src repository
|
||||
$ conda env create -f src/config_projet.yml
|
||||
2 - Activate the generated environment
|
||||
$ conda activate projet-court
|
||||
|
||||
toy-example:
|
||||
md.pdb contains structural information of 501 conformations of the calf-1 domain
|
||||
|
||||
3 - try the program on md.pdb
|
||||
$ python3 src/projet8 data/md.pdb
|
||||
|
||||
This will generate a md.csv file in the results folder, representing a dataframe of the conformations, each row being a conformation and each column a PB position
|
||||
|
||||
Informations:
|
||||
|
||||
The pdb was obtained from .trr and .gro files available online (http://www.dsimb.inserm.fr/~tmp/DM_Calf-1_WT_production_long1.tar.gz)
|
||||
pbd was generated using gromacs :
|
||||
$ trjconv -f md.trr -s md -o md.pdb
|
||||
|
|
@ -1,30 +0,0 @@
|
|||
>test_data/barstar_md_traj.xtc | frame 0
|
||||
ZZdddfklpmbfklmmmmmmmmnopafklgoiaklmmmmmmmmpacddddddehklmmmm
|
||||
moghilmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 1
|
||||
ZZdddfklpcbfklmmmmmmmmnopafkbghiaklmmmmmmmmpccddddddehklmmmm
|
||||
moghklmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 2
|
||||
ZZdddfklpcbfklmmmmmmmmnopafkbgoiaklmmmmmnopaacddddddehklmmmm
|
||||
mpghklmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 3
|
||||
ZZdddfklpcbfklmmmmmmmmnopafkbgoiaklmmmmmmmmpccddddddehklmmmm
|
||||
mbghilmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 4
|
||||
ZZdddfklpcbfklmmmmmmmmnopafkbghiaklmmmmmmmmpccddddddehklmmmm
|
||||
mcehilmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 5
|
||||
ZZdddfklgcbfklmmmmmmmmnopafkbgoiaklmmmmmmmmpccddddddehklmmmm
|
||||
mbghklmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 6
|
||||
ZZdddfklpcbfklmmmmmmmmnopafkbghiaklmmmmmmmmpccddddddehklmmmm
|
||||
mbghklmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 7
|
||||
ZZdddfklpgbfklmmmmmmmmnopafklgoiaklmmmmmmmmpccddddddehkllmmm
|
||||
mbghklmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 8
|
||||
ZZdddfklpcbfklmmmmmmmmnopafklgoiaklmmmmmmmmpccddddddehklmmmm
|
||||
npghklmmmmmmmmmmmmnopacddddZZ
|
||||
>test_data/barstar_md_traj.xtc | frame 9
|
||||
ZZdddfklpcbfklmmmmmmmmnopafkbgoiaklmmmmmmmmmccddddddehkllmmm
|
||||
mbghklmmmmmmmmmmmmnopacddddZZ
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,24 @@
|
|||
#!/bin/python3
|
||||
|
||||
import pandas as pd
|
||||
import pbxplore as pbx
|
||||
import sys
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) != 2:
|
||||
print("Error : usage $ python3 projet8 md.pdb")
|
||||
exit()
|
||||
|
||||
conformations = [] # list to store PB format chains
|
||||
|
||||
for chain_name, chain in pbx.chains_from_files([sys.argv[1]]):
|
||||
dihedrals = chain.get_phi_psi_angles()
|
||||
pb_seq = pbx.assign(dihedrals)
|
||||
conformations.append(pb_seq)
|
||||
|
||||
df = pd.DataFrame() # pandas dataframe to store conformations
|
||||
|
||||
for conf in conformations:
|
||||
df = df.append(pd.Series(list(conf)), ignore_index=True)
|
||||
|
||||
df.to_csv("results/md.csv", index=False)
|
||||
Loading…
Reference in New Issue