muon.pp.filter_var(data: AnnData | MuData, var: str | Sequence[str], func: Callable | None = None)#

Filter variables (features, e.g. genes) in-place using any column in .var or row in .X.

  • data (AnnData or MuData) – AnnData or MuData object

  • var (str or Sequence[str]) – Column name in .var or row name in .X to be used for filtering. Alternatively, var_names can be provided directly.

  • func – Function to apply to the variable used for filtering. If the variable is of type boolean and func is an identity function, the func argument can be omitted.