Get the App
SLTechnology News&Howtos  ›  Development  › 

How to use R packet mclust to cluster samples

Shulou Source: shulou.com Published: 2022-06-01 04:35:16 09月22日 Update

Most people do not understand the knowledge points of this article "how to cluster samples with R packet mclust", so the editor summarizes the following contents, detailed content, clear steps, and has a certain reference value. I hope you can get something after reading this article. Let's take a look at this "how to cluster samples with R packet mclust" article.

Usage: $Rscript.. / scripts/mclust_analysis.r-husage:.. / scripts/mclust_analysis.r [- h]-I gene_data-m metadata [--mclust] [- g group] [- n model_name] [- o outdir] [- p prefix] mclust analysis: https://www..com/article/1580optional arguments:-h -- help show this help message and exit-I gene_data,-- gene_data gene_data input data file path [required]-m metadata,-- metadata metadata input clinical information file path [required]-- mclust whether to cluster the samples [optional,default:False]-g group -- group group Group the samples into several categories [optional,default:3]-n model_name,-- model_name model_name input the model category to use [optional,default:VVE]-o outdir,-- outdir outdir output file directory [optional,default cwd]-p prefix -- prefix prefix out file name prefix [optional,default metadata] parameter description:

-I input gene expression data:

ID

TCGA-A3-3319-01A-02R-1325-07

TCGA-A3-3323-01A-02R-1325-07

YTHDC2

16.5128725081007

20.6535652352011

ELAVL1

44.3876796198438

31.8729000784291

-m input clinical information of the sample:

Barcode

Patient

TCGA_Study

TCGA-A3-3319-01A-02R-1325-07

TCGA-A3-3319

KIRC

TCGA-A3-3323-01A-02R-1325-07

TCGA-A3-3323

KIRC

-- whether mclust clusters the samples

The script is not clustered for the first time, and the appropriate number of clusters and model categories are selected through the returned BIC (Bayesian Information Discriminant criteria) results.

-n enter the selected model category

Fourteen models are available in the mclust package (EII, VII, EEI, VEI, EVI, VVI, EEE, EVE, VEE, VVE, EEV, VEV, EVV, VVV)

-g enter the appropriate number of clusters

Examples of use:

# do not specify g and n for the first run, and select the appropriate g and n through the BIC result

$Rscript. / scripts/mclust_analysis.r-I m6a_gene_TPM.tsv-m. / metadata_surv_immu.tsv

# run the specified g and n again for clustering

Rscript. / scripts/mclust_analysis.r-I m6a_gene_TPM.tsv\-m.. / metadata_surv_immu.tsv-- mclust-g 3-n VVE above is about "how to use R packet mclust to cluster samples". I believe everyone has a certain understanding. I hope the content shared by the editor will be helpful to you. If you want to know more about the relevant knowledge, please follow the industry information channel.

Tags: Samples content input fit model run selection information article knowledge first time article category result value method of use again parameters genes most Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MariaDB Xiaomi Linux Docker Shulou Technology