matteoferla / MEF2C_analysis

Analysis of variants of MEF2C
MIT License
1 stars 0 forks source link

Usage instructions needed #1

Closed jaacoppi closed 3 years ago

jaacoppi commented 3 years ago

Currently the documentation is sparse. Can you extend Readme.md to provide the usage instructions to obtain the results mentioned in your article "Non-coding region variants upstream of MEF2C cause severe developmental disorderthrough three distinct loss-of-function mechanisms"?

1) What are the requirements for the pipeline (what data needs to be present, what python modules are needed) 2) which python file should be called, what parameters should be used?

matteoferla commented 3 years ago

Sorry, this was meant to be a note of the operations performed as part of the methods for the paper and never a pipeline. In fact, none of the Python files were actually ever python files, but Jupyter notebooks, which only recently GitHub has been displaying nicely.

The Python version used is 3.7, but would work with 3.8 —the code may have typehints, which are incompatible with 3.6. The version of Pyrosetta was likely linux 2020.49.

Due to the similarity of MEF2C and MEF2A, no fancy threading was done, but simply taken from SwissModel and then cleaned with the code in model_prep.py where each section was actually a cell.

The mutagenesis was done with snippets from mutagenesis.py, which import variant.py, which is a legitimate Python file.

However, since publication I have re-used the code, but put in its own repo/pip-released module. Namely, say one has an energy minimised pose (pose):

from pyrosetta_help import MutantScorer, Mutation, extend_scores
model = MutantScorer(pose, modelname='test')
model.scorefxn = pyrosetta.create_score_function('ref2015')
model.strict_about_starting_residue = True
data = model.score_mutations(['p.Met1Gly', 'p.Ser29Glu'],
                            chains='V',
                            interfaces=(('isolated', 'V_ABCDEFGHIJKLMNOPQRSTWXYZ'),),
                            preminimise=True,
                            distance=15,
                            cycles=5)

import pandas as pd
scores = pd.DataFrame(data)
extend_scores(scores)

The polishing and minimisation of the pose, would depend on the model in question —e.g. large structure requires LocalRelax, some cryoEM structures have weird maps, ligands need parameterising, AlphaFold2 models may need pLDDT-based constraints etc. etc.

jaacoppi commented 3 years ago

Thanks! This is enough.