HOW TO READ A TSV FILE TO A NUMERIC IN r code example
Example 1: r how to import tsv file
read.table(file = 'drug_info.tsv', sep = '\t', header = TRUE)
Example 2: read tsv file column
#for example you have 4 column age,gender,name,adress
#if you want to gender you should give "line[1]" for arraylist
with open("train.tsv",encoding='utf8') as tsvfile:
tsvreader = csv.reader(tsvfile, delimiter="\t")
for line in tsvreader:
print(line[1])