[Bioc-devel]  Strange "internal logical NA value has been modified" error
    Hervé Pagès 
    hp@ge@@on@g|thub @end|ng |rom gm@||@com
       
    Wed Oct 13 18:43:40 CEST 2021
    
    
  
Hi Pariksheet,
On 12/10/2021 15:43, Pariksheet Nanda wrote:
> 
> The function in question is:
> 
> 
> replace_unstranded <- function (gr) {
>      idx <- strand(gr) == "*"
>      if (length(idx) == 0L)
            ^^^^^^^^^^^^^^^^^
Not related to the "internal logical NA value has been modified" error 
but shouldn't you be doing '!any(idx)' instead of 'length(idx) == 0L' here?
Best,
H.
>          return(gr)
>      sort(c(
>          gr[! idx],
>          `strand<-`(gr[idx], value = "+"),
>          `strand<-`(gr[idx], value = "-")))
> }
> 
> 
-- 
Hervé Pagès
Bioconductor Core Team
hpages.on.github using gmail.com
    
    
More information about the Bioc-devel
mailing list