Skip to content
Snippets Groups Projects

Added comments and changed variables names

Merged agata.t.wyrozemska requested to merge loading_files into main
1 file
+ 3
3
Compare changes
  • Side-by-side
  • Inline
+ 3
3
@@ -2,11 +2,12 @@
"""
Created on Mon Jun 27 18:09:27 2022
@author: Gimli
@author: Agata and Amrinder
"""
import pandas as pd
def seq_loader(file_dir):
"""seq_loader: can be used to read the input files and recognize fasta format features"""
fasta_seq = {}
with open(file_dir) as file_one:
for line in file_one:
@@ -20,16 +21,15 @@ def seq_loader(file_dir):
else:
sequence = line
fasta_seq[active_sequence_name].append(sequence)
print(fasta_seq)
return fasta_seq
def octamer_loader(file_dir_oct):
"""octamer_reader: can be used to read octamer list from .txt files into pandas dataframe"""
octamer_seq = pd.read_csv(file_dir_oct,
header = 0 ,
skiprows = (22),
sep = ",",
index_col = False)
print(octamer_seq)
return octamer_seq
Loading