Is there a way to set the set check.limits=FALSE when you call this function from BioStrings....
Method("as.character", "XStringViews",
function(x, use.names=TRUE, check.limits=TRUE)
{
if (!isTRUEorFALSE(check.limits))
stop("'check.limits' must be TRUE or FALSE")
if (check.limits)
out.of.limits <- "error"
else
out.of.limits <- "warning"
y <- fromXStringViewsToStringSet(x, out.of.limits=out.of.limits,
use.names=use.names)
as.character(y)
}
)
I believe this will allow for automatic trimming if desired.
"as.character(x, use.names=TRUE, check.limits=TRUE): Converts x to a character vector of the same length as x. The use.names argument controls whether or not names(x) should be propagated to the names of the returned vector. The check.limits argument controls whether or not an error should be raised if x has "out of limit" views. If check.limits is FALSE then "out of limit" views are trimmed with a warning."
Right now it just errors out with this statement....
""" Error in fromXStringViewsToStringSet(x, out.of.limits = out.of.limits, :
'x' has "out of limits" views
Calls: sgRNA_design ... as.character -> .local -> fromXStringViewsToStringSet
Execution halted"""
Is there a way to set the set check.limits=FALSE when you call this function from BioStrings....
Method("as.character", "XStringViews", function(x, use.names=TRUE, check.limits=TRUE) { if (!isTRUEorFALSE(check.limits)) stop("'check.limits' must be TRUE or FALSE") if (check.limits) out.of.limits <- "error" else out.of.limits <- "warning" y <- fromXStringViewsToStringSet(x, out.of.limits=out.of.limits, use.names=use.names) as.character(y) } )
I believe this will allow for automatic trimming if desired. "as.character(x, use.names=TRUE, check.limits=TRUE): Converts x to a character vector of the same length as x. The use.names argument controls whether or not names(x) should be propagated to the names of the returned vector. The check.limits argument controls whether or not an error should be raised if x has "out of limit" views. If check.limits is FALSE then "out of limit" views are trimmed with a warning." Right now it just errors out with this statement.... """ Error in fromXStringViewsToStringSet(x, out.of.limits = out.of.limits, : 'x' has "out of limits" views Calls: sgRNA_design ... as.character -> .local -> fromXStringViewsToStringSet Execution halted"""