Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

extractSignature non-conformable arrays error #119

Closed
dschslava opened this issue Feb 1, 2018 · 11 comments
Closed

extractSignature non-conformable arrays error #119

dschslava opened this issue Feb 1, 2018 · 11 comments

Comments

@dschslava
Copy link

Dear PoisonAlien,

I tried to run the following command and I got an error message saying that All the runs produced an error.

I got the hg19.fa from UCSC this afternoon.

I can run the following commands with no problem.

plotApobecDiff(tnm = laml.tnm, maf = laml)

Thanks in advance!

laml.sign = extractSignatures(mat = laml.tnm, nTry = 6, plotBestFitRes = FALSE)
Estimating best rank..
Timing stopped at: 0.055 0.001 0.075
Timing stopped at: 1.219 0.015 1.26
Timing stopped at: 0.055 0 0.054
Timing stopped at: 0.629 0.002 0.631
Timing stopped at: 0.011 0 0.012
Timing stopped at: 0.516 0.001 0.516
Timing stopped at: 0.042 0.003 0.044
Timing stopped at: 0.543 0.006 0.544
Timing stopped at: 0.014 0 0.014
Timing stopped at: 0.515 0.003 0.514
Error in (function (...) : All the runs produced an error:
-#1 [r=2] -> non-conformable arrays [in call to '!=']
-#2 [r=3] -> non-conformable arrays [in call to '!=']
-#3 [r=4] -> non-conformable arrays [in call to '!=']
-#4 [r=5] -> non-conformable arrays [in call to '!=']
-#5 [r=6] -> non-conformable arrays [in call to '!=']

@PoisonAlien
Copy link
Owner

Hello,

Try loading nmf library first and see if it works.

library('NMF')
laml.sign = extractSignatures(mat = laml.tnm, nTry = 6, plotBestFitRes = FALSE)

@dschslava
Copy link
Author

Yes I loaded the NMF library first by doing the following:

require('NMF')
laml.sign = extractSignatures(mat = laml.tnm, nTry = 6, plotBestFitRes = FALSE)

I also ran the lamb.tnm = trinucleotideMatrix () command by specifying the file path to hg19 before loading the NMF library and it worked correctly.

Here is my screenshot for the error.

require('NMF')
laml.sign = extractSignatures(mat = laml.tnm, nTry = 6, plotBestFitRes = FALSE)
Estimating best rank..
Timing stopped at: 0.011 0.001 0.021
Timing stopped at: 0.508 0.002 0.518
Timing stopped at: 0.03 0.005 0.036
Timing stopped at: 0.553 0.014 0.572
Timing stopped at: 0.012 0 0.013
Timing stopped at: 0.513 0.003 0.512
Timing stopped at: 0.012 0 0.012
Timing stopped at: 0.528 0.007 0.534
Timing stopped at: 0.011 0.001 0.011
Timing stopped at: 0.528 0.007 0.535
Error in (function (...) : All the runs produced an error:
-#1 [r=2] -> non-conformable arrays [in call to '!=']
-#2 [r=3] -> non-conformable arrays [in call to '!=']
-#3 [r=4] -> non-conformable arrays [in call to '!=']
-#4 [r=5] -> non-conformable arrays [in call to '!=']
-#5 [r=6] -> non-conformable arrays [in call to '!=']

@PoisonAlien
Copy link
Owner

Hi,
How many samples do you have ? and whats the mutations rate per sample ?

@dschslava
Copy link
Author

Here is the sample size information:
$SampleSummary
Cohort SampleSize
1: Enriched 4
2: nonEnriched 172

getSampleSummary(laml)
Tumor_Sample_Barcode Frame_Shift_Del Frame_Shift_Ins In_Frame_Del In_Frame_Ins Missense_Mutation Nonsense_Mutation Splice_Site total
1: TCGA-AB-3009 0 5 0 1 25 2 1 34
2: TCGA-AB-2807 1 0 1 0 16 3 4 25
3: TCGA-AB-2959 0 0 0 0 22 0 1 23
4: TCGA-AB-3002 0 0 0 0 15 1 5 21
5: TCGA-AB-2849 0 1 0 0 16 1 2 20


188: TCGA-AB-2933 0 0 0 0 1 0 0 1
189: TCGA-AB-2942 0 0 0 1 0 0 0 1
190: TCGA-AB-2946 0 0 0 0 1 0 0 1
191: TCGA-AB-2954 0 0 0 0 1 0 0 1
192: TCGA-AB-2982 0 0 0 0 1 0 0 1

@dschslava
Copy link
Author

Here is where the hp19.fa is located:
https://drive.google.com/open?id=19ZVaNWzOXebaxE5OY24WWZKtQMHcAAwc

Please let me know if you need permission to download.

@WatsonCrick2018
Copy link

Could you share with me where your hg19.fa is located so I can try it out?

@PoisonAlien
Copy link
Owner

@dschslava Hi,
Can you upload your tnm matrix here ? You can write it to a tsv file and attach it here..

write.table(laml$nmf_matrix, "tnm.tsv", sep = "\t", quote = FALSE)

Keep rownames.

@dschslava
Copy link
Author

Dear PoisonAlien,

Thank you for the instruction. I got the following error:

write.table(laml$nmf_matrix, "tnm.tsv", sep = "\t", quote = FALSE)
Error in laml$nmf_matrix : $ operator not defined for this S4 class

@PoisonAlien
Copy link
Owner

Oh, Sorry my mistake.
Try this laml.tnm$nmf_matrix

@dschslava
Copy link
Author

Dear PoisonAlien,

This time it worked but I don't know where to find tam.tsv file. It is not in extdata.

write.table(laml.tnm$nmf_matrix, "tnm.tsv", sep = "\t", quote = FALSE)

Thanks!

@dschslava
Copy link
Author

dschslava commented Feb 9, 2018 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants