discrimintools.summaryMPCA#
- discrimintools.summaryMPCA(obj, digits=4, nb_element=10, ncp=3, to_markdown=False, tablefmt='github', **kwargs)[source]#
-
Printing summaries of Mixed Principal Component Analysis model.
- Parameters:
-
digits (int, default = 4) – The number of decimal printed.
nb_element (int,, default = 10) – Number of element
ncp (int,, default = 3) – Number of components
to_markdown (bool, default = False) – To print summaries in markdown-friendly format. Requires the tabulate. package.
tablefmt (str, default = “github”) – The table format.
**kwargs – additionals parameters. These parameters will be passed to tabulate.
- Return type:
-
NoneType
See also
summaryGFA-
Printing summaries of General Factor Analysis model.
summaryGFALDA-
Printing summaries of General Factor Analysis Linear Discriminant Analysis model.
summaryMDA-
Printing summaries of Mixed Discriminant Analysis model.
Examples
>>> from discrimintools.datasets import load_heart >>> from discrimintools import MPCA, summaryMPCA >>> D = load_heart("subset") >>> X = D.drop(columns=["disease"]) >>> clf = MPCA() >>> clf.fit(X) MPCA() >>> summaryMPCA(clf) Mixed Principal Component Analysis - Results Eigenvalues informations: Can1 Can2 Can3 Can4 ... Can7 Can8 Can9 Can10 Variance 3.5040 2.0055 1.8996 1.3246 ... 0.9318 0.8633 0.7418 0.4526 Difference 1.4985 0.1059 0.5750 0.1522 ... 0.0684 0.1215 0.2892 NaN % of var. 25.0288 14.3249 13.5684 9.4616 ... 6.6555 6.1667 5.2988 3.2328 Cumulative % of var. 25.0288 39.3536 52.9220 62.3837 ... 85.3017 91.4684 96.7672 100.0000 [4 rows x 10 columns] Individuals (the 10 first): Can1 Can2 0 0.4813 -0.3691 1 -1.5953 -0.7913 2 0.4499 5.0389 3 1.4228 0.1799 4 0.0194 -0.3433 5 0.0610 -0.3194 6 -3.8725 4.3323 7 -2.5126 -0.3472 8 -0.2793 -0.2635 9 -3.4851 -1.5245 Variables (the 10 first): Can1 Can2 age -0.5010 0.1554 restbpress -0.3558 0.1148 max_hrate 0.6681 0.0688 asympt -0.7169 -0.2320 atyp_angina 0.5061 0.1254 non_anginal 0.2706 0.0883 typ_angina 0.1312 0.1470 f 0.3192 -0.9171 t -0.3192 0.9171 left_vent_hyper 0.0567 0.1085