You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was trying to use the plotFeatureDist() function to visualize a set of distances in comparison to a set of background distances. However, the function takes as input the bgdists parameter but when this parameter is not NULL, the code block for this feature looks for a parameter named bgDists.
GenomicDistributions::plotFeatureDist(dists = kataegis_dist,
bgdists = non_clustered_dist,
featureName = "Kataegis Mutations",
size = 5e5)
Error in cutDists(bgDists, divisions = NULL, nbins, size, infBins) :
object 'bgDists' not found
I tested changes to the parameter name and it solved that issue. However there was 1 additional error that appears related to the last line in that block:
Error in set(x, j = name, value = value) :
Supplied 99 items to be assigned to 100 items of column 'bgX'. If you wish to 'recycle' the RHS please use rep() to make this intent clear to readers of your code.
A workaround I implemented that produced working plots was the following:
df$bgX = rep(seq_len(nrow(bgDistsDF)-1), nplots)
changed to df$bgX = rep(seq_len(nrow(bgDistsDF)), nplots)
Hope this description of the error is helpful.
Best,
Patrick
The text was updated successfully, but these errors were encountered:
Hello,
I was trying to use the
plotFeatureDist()
function to visualize a set of distances in comparison to a set of background distances. However, the function takes as input thebgdists
parameter but when this parameter is notNULL
, the code block for this feature looks for a parameter namedbgDists
.See the block below from GenomicDistributions/R/feature-plots.R
I tested changes to the parameter name and it solved that issue. However there was 1 additional error that appears related to the last line in that block:
A workaround I implemented that produced working plots was the following:
df$bgX = rep(seq_len(nrow(bgDistsDF)-1), nplots)
changed to
df$bgX = rep(seq_len(nrow(bgDistsDF)), nplots)
Hope this description of the error is helpful.
Best,
Patrick
The text was updated successfully, but these errors were encountered: