Giter Club home page Giter Club logo

Comments (2)

JEFworks avatar JEFworks commented on June 17, 2024

It looks like for your grouping vector, you are setting some cells to NA then converting that vector into a factor so β€˜NA’ is being treated as a factor grouping. You will need to convert to a factor first, then set cells to NA such that levels(grouping_factor) only has 2 levels.

ex.

> groups <- factor(gsub("(MEF|ESC).*", "\\1", rownames(o.ifm)), levels  =  c("ESC", "MEF"))
> names(groups) <- row.names(o.ifm)
> 
> groups
ESC_10 ESC_11 ESC_12 ESC_13 ESC_14 ESC_15 ESC_16 ESC_17 ESC_18 ESC_19  ESC_1 ESC_20 
   ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC 
ESC_21 ESC_22 ESC_23 ESC_24 ESC_25 ESC_26 ESC_27 ESC_28 MEF_49 MEF_50 MEF_51 MEF_52 
   ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    MEF    MEF    MEF    MEF 
MEF_53 MEF_54 MEF_55 MEF_56 MEF_57 MEF_58 MEF_59 MEF_60 MEF_61 MEF_62 MEF_63 MEF_64 
   MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF 
MEF_65 MEF_66 MEF_67 MEF_68 
   MEF    MEF    MEF    MEF 
Levels: ESC MEF
> groups[1] <- NA
> groups
ESC_10 ESC_11 ESC_12 ESC_13 ESC_14 ESC_15 ESC_16 ESC_17 ESC_18 ESC_19  ESC_1 ESC_20 
  <NA>    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC 
ESC_21 ESC_22 ESC_23 ESC_24 ESC_25 ESC_26 ESC_27 ESC_28 MEF_49 MEF_50 MEF_51 MEF_52 
   ESC    ESC    ESC    ESC    ESC    ESC    ESC    ESC    MEF    MEF    MEF    MEF 
MEF_53 MEF_54 MEF_55 MEF_56 MEF_57 MEF_58 MEF_59 MEF_60 MEF_61 MEF_62 MEF_63 MEF_64 
   MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF    MEF 
MEF_65 MEF_66 MEF_67 MEF_68 
   MEF    MEF    MEF    MEF 
Levels: ESC MEF

from scde.

ulah avatar ulah commented on June 17, 2024

yes, that was the problem, thanks!

from scde.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.