opendvp.pp.impute_marker_with_annotation#
- impute_marker_with_annotation(adata, target_variable, target_annotation_column, quantile_for_imputation=0.05)#
- Change value of a feature in an AnnData object for rows matching a specific annotation. - Using a specified quantile value from the variable’s distribution. - Return type:
 - Parameters:#- adataad.AnnData
- The annotated data matrix. 
- target_variablestr
- The variable (gene/feature) to impute. 
- target_annotation_columnstr
- The column in adata.obs to use for selecting rows to impute. 
- quantile_for_imputationfloat, optional
- The quantile to use for imputation (default is 0.05). 
 - Returns:#- ad.AnnData
- A copy of the AnnData object with imputed values.