Writing /users/jbklauda/pub/wiki/data/cache/6/6193a558dc90ed4c190004bf67ecff70.captchaip failed
pairwise_2d-rdf_and_clustering
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| pairwise_2d-rdf_and_clustering [2020/08/24 19:59] – edit | pairwise_2d-rdf_and_clustering [2022/10/23 21:33] (current) – [Pairwise 2D-RDF and Clustering Analysis] edit | ||
|---|---|---|---|
| Line 7: | Line 7: | ||
| Bug fix log: | Bug fix log: | ||
| - | 08/24/2020: An asymmetric membrane only bug found in clustering.py (line # 757), status: code fixed and updated, example not updated. | + | 08/24/2020: An asymmetric membrane only bug found in clustering.py (line # 757); status: code fixed and updated, example not updated. |
| {{ : | {{ : | ||
| Line 46: | Line 46: | ||
| conda create -n cluster -c omnia python=3.6 openmm mdtraj numpy scikit-learn matplotlib | conda create -n cluster -c omnia python=3.6 openmm mdtraj numpy scikit-learn matplotlib | ||
| - | Using this command, we created a conda environment (env) called " | + | Using this command, we created a conda environment (env) called " |
| Line 59: | Line 59: | ||
| Note this RDF code also allows self-RDF (just make the two atom selection words the same). | Note this RDF code also allows self-RDF (just make the two atom selection words the same). | ||
| + | |||
| + | |||
| (3) The clustering code | (3) The clustering code | ||
| Line 102: | Line 104: | ||
| * use lower case for head group name but upper case for atom name. | * use lower case for head group name but upper case for atom name. | ||
| - | b. In **run_cluster.py**, | + | b. In **run_cluster.py**, |
| - | Submit the clustering analysis by " | + | c. Include ALL lipids in your system. |
| + | |||
| + | d. Other changes should follow the instructions in the code. | ||
| + | |||
| + | |||
| + | |||
| + | (4) The util.py | ||
| + | |||
| + | a. Make corresponding edits in util.py (could copy from run_cluster.py) before submitting job | ||
| + | |||
| + | b. Submit the clustering analysis by " | ||
| **Check the results:** | **Check the results:** | ||
| Line 116: | Line 128: | ||
| * in topsize.png / botsize.png, | * in topsize.png / botsize.png, | ||
| - | c. If you want to visualize the clusters, please use the visualize.py file. Usually it takes about 10 seconds to generate two cluster pictures (upper& | + | (5) Visualization |
| + | |||
| + | If you want to visualize the clusters, please use the visualize.py file. | ||
| + | |||
| + | a. activate conda environment | ||
| + | |||
| + | b. Make corresponding edits in visualize.py | ||
| + | |||
| + | c. define colors for different headgroups at the beginning of clustering.py. | ||
| + | |||
| + | < | ||
| + | def color_(head): | ||
| + | # used for cluster visualization | ||
| + | if head == ' | ||
| + | return ' | ||
| + | elif head == ' | ||
| + | return ' | ||
| + | elif head == ' | ||
| + | return ' | ||
| + | elif head == ' | ||
| + | return ' | ||
| + | elif head == ' | ||
| + | return ' | ||
| + | elif head == ' | ||
| + | return ' | ||
| + | elif head == ' | ||
| + | return ' | ||
| + | </ | ||
| + | |||
| + | * Could also use //" | ||
| + | |||
| + | d. You can define what's included in the cluster plot by editing the // | ||
| + | |||
| + | e. Usually it takes about 10 seconds to generate two cluster pictures (upper& | ||
pairwise_2d-rdf_and_clustering.1598313580.txt.gz · Last modified: 2020/08/24 19:59 by edit