Skip to content
Snippets Groups Projects
Commit 51ce05e5 authored by Max Bär's avatar Max Bär
Browse files

Merge branch 'feature_max' into 'main'

First uncleaned version able to generate GTF output file

See merge request !28
parents 8ce6a446 d562cf09
No related branches found
No related tags found
2 merge requests!31Main,!28First uncleaned version able to generate GTF output file
...@@ -62,7 +62,19 @@ class CreateTranscript(): ...@@ -62,7 +62,19 @@ class CreateTranscript():
return self.df return self.df
transcripts = CreateTranscript() transcripts = CreateTranscript()
interaction_df = transcripts.generate_interaction_df() interaction_df = transcripts.generate_interaction_df()
#print line by line to file and then you're done
output = str()
for i in interaction_df.index:
#print(interaction_df[3][i]+'\t' + 'RIBlast' + '\t' + 'Priming_site' + '\t' + interaction_df[13][i] + '\t' + interaction_df[12][i] + '\t' + '.' + '\t' + '+' + '\t' + '.' + '\t' + f'Accessibility_Energy "{interaction_df["Interaction Energy"][i]}"')
output = output + str(interaction_df[3][i]+'\t' + 'RIBlast' + '\t' + 'Priming_site' + '\t' + interaction_df[13][i] + '\t' + interaction_df[12][i] + '\t' + '.' + '\t' + '+' + '\t' + '.' + '\t' + f'Accessibility_Energy "{interaction_df["Interaction Energy"][i]}"' + '\n')
print(output)
with open('output_transcripts_df.txt', 'w') as f:
f.write(output)
Transcript_1 RIBlast Priming_site 2974 2988 . + . Accessibility_Energy "0.08051396365277928"
Transcript_1 RIBlast Priming_site 4 18 . + . Accessibility_Energy "0.17770481173297115"
Transcript_2 RIBlast Priming_site 1270 1284 . + . Accessibility_Energy "0.6445369481689498"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment