text: user9234: I am pretty new to Seurat. I want to subset from my original seurat object (BC3) meta.data based on orig.ident. however, when i use subset(), it returns with Error.
  ER_HER_P <- subset(BC3, idents = c("BC03"))
  Error: No cells found
  
  table(Idents(BC3))
  BC01   BC02   BC03 BC03LN   BC04   BC05   BC06   BC07 BC07LN   BC08   BC09   BC10   BC11 
  21     50     33     51     42     74     15     48     52     21     55     13     11 
  
  There are 33 cells under the identity. I checked the active.ident to make sure the identity has not shifted to any other column, but still I am getting the error?
  head(BC3@active.ident)
  [1] BC01 BC01 BC01 BC01 BC01 BC01
  Levels: BC01 BC02 BC03 BC03LN BC04 BC05 BC06 BC07 BC07LN BC08 BC09 BC10 BC11
  
  
  user2388: If you are going to use idents like that, make sure that you have told the software what your default ident category is.
  This works for me, with the metadata column being called "group", and "endo" being one possible group there.
  Idents(combined.all) <- "group"
  endo_subset <- subset(combined.all, idents = c("endo"))
  
  I think this is basically what you did, but I think this looks a little nicer
  
original_text: 9234: <p>I am pretty new to Seurat. I want to subset from my original seurat object (BC3) meta.data based on orig.ident. however, when i use subset(), it returns with Error.</p>
  <pre><code>ER_HER_P &lt;- subset(BC3, idents = c(&quot;BC03&quot;))
  Error: No cells found
  
  table(Idents(BC3))
  BC01   BC02   BC03 BC03LN   BC04   BC05   BC06   BC07 BC07LN   BC08   BC09   BC10   BC11 
  21     50     33     51     42     74     15     48     52     21     55     13     11 
  </code></pre>
  <p>There are 33 cells under the identity. I checked the active.ident to make sure the identity has not shifted to any other column, but still I am getting the error?</p>
  <pre><code>head(BC3@active.ident)
  [1] BC01 BC01 BC01 BC01 BC01 BC01
  Levels: BC01 BC02 BC03 BC03LN BC04 BC05 BC06 BC07 BC07LN BC08 BC09 BC10 BC11
  </code></pre>
   2388: <p>If you are going to use idents like that, make sure that you have told the software what your default ident category is.</p>
  <p>This works for me, with the metadata column being called &quot;group&quot;, and &quot;endo&quot; being one possible group there.</p>
  <pre><code>Idents(combined.all) &lt;- &quot;group&quot;
  endo_subset &lt;- subset(combined.all, idents = c(&quot;endo&quot;))
  </code></pre>
  <p>I think this is basically what you did, but I think this looks a little nicer</p>
  