imgag/ClinCNV

Trios sample ID

sunyihong opened this issue · 6 comments

Hello, clinCNV analyzed 5 trios, there was an error occurred. Is my sample ID's problem?
below is my sample ID file:
1_cyw,1_cywm,1_cywf
11_ywx,11_ywxm,11_ywxf
10_xjx,10_xjxm,10_xjxf
12_zxy,12_zxym,12_zxyf
13_zmh,13_zmhm,13_zmhf

There is error message:
[1] Error in strsplit(genesThatHasToBeSeparated[i], split = ",") :
[2]non-character argument
[3]Calls: source ... eval -> eval -> plotFoundCNVs -> unlist -> strsplit
[4]Execution halted

Thanks

Hi, yes, ClinCNV (actually - R) does not like sample names starting with numbers, but I guess the problem is in a different piece of code. What is in the 5th column of your BED file? Gene names separated by commas, if multiple genes intersect in one position?

Thank you for you reply,I edited the sample ID, but the error still as above.
My BED file only has 4 columns, no gene column,
like this: chr1 12080 12251 0.4912
chr1 12595 12802 0.6232

Could you modify this file in your local copy https://github.com/imgag/ClinCNV/blob/4c840af6b2d39b363bd908797e10a20830599cb0/trios/helpersTrio.R
add
print(genesThatHasToBeSeparated)
just after the definition of this variable? It is defined at line 27.

I modified the code according to your suggestion, but it still didn't work. the output log as below:
[1] "chrY"
[1] "Amount of regions after low covered regions filtering (median < 0.3) in cluster 0 : 97.18"
[1] "We analyse trio"
Kid Mother Father
1 P1_cyw P1_cywm P1_cywf
[1] 0

the last four trios didn't call.

Ah I see! So remove this "print" thing. Could you modify helpersTrio.R the same way as the other helpers https://github.com/search?q=repo%3Aimgag%2FClinCNV%20genesThatHasToBeSeparated&type=code - by adding
if (is.character(genesThatHasToBeSeparated[i]))

right before vectorOfGeneNames = c(vectorOfGeneNames, unlist(strsplit(genesThatHasToBeSeparated[i], split=",")))

It works! Thank you