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

scar_score() with allele-specific segmentation file fails with Error in [.data.frame(seg, , 8) : undefined columns selected #7

Open
ThomasGro opened this issue Feb 14, 2020 · 6 comments

Comments

@ThomasGro
Copy link

Hi,
I have generated a allele-specific segmentation file with CNVkit. I adapted the format to fit your input
"... allele-specific segmentation file with the following columns: 1st column: sample name, 2nd column: chromosome, 3rd column: segmentation start, 4th column: segmentation end, 5th column: total copynumber, 6th column: copy number of A allele, 7th column: copy number of B allele"

sample_name chromosome segment_start segment_end tcn nA nB
model1 1 62676830 62677251 30 19 11
model1 1 173836085 177898343 3 2 1
model1 2 677597 1217588 5 4 1

But I get the error:

scar_score("./x.tsv", reference = "grch37")
Error in [.data.frame(seg, , 8) : undefined columns selected

It seems the function is expecting an additional column?!

Thank you for your support,
Thomas

@ThomasGro
Copy link
Author

One add on:
when I add another column wioth ploidy information as in your example file:

sample_name chromosome segment_start segment_end tcn nA nB ploidy
model1 1 62676830 62677251 30 19 11 2
model1 1 173836085 177898343 3 2 1 2
model1 2 677597 1217588 5 4 1 2

I get:

scar_score("./x.tsv", reference = "grch37")
Determining HRD-LOH, LST, TAI
Error in write.table(t(HRDresulst), paste0(outputdir, "/", run_name, "_HRDresults.txt"), :
invalid 'row.names' specification

@zhjianli
Copy link

scar_score processes one sample each time.

@ThomasGro
Copy link
Author

ThomasGro commented Jan 26, 2021 via email

@sheny-bio
Copy link

I had exactly the same issue. Did you solve the problem eventually? Thanks.

@ThomasGro
Copy link
Author

Please look at my comment from Jan 26th.
You have to reorder the columns of the input table - at least that worked for me.

@jwuatx
Copy link

jwuatx commented Oct 27, 2023

5: number of probes

Did this work correctly? I think their test file only has 8 columns with "ploidy" in the end

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

4 participants