{
"cells": [
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "080858dc-1994-4cce-be1d-dc1538afa06c"
}
},
"source": [
"## Part 4. Multivariate Statistics\n",
"$$ \\def\\pr{\\hbox{Pr}}\n",
"\\def\\var{\\hbox{var}}\n",
"\\def\\cov{\\hbox{cov}}\n",
"\\def\\corr{\\hbox{corr}}\n",
"\\def\\dmX{\\un{\\mathcal{X}}}\n",
"\\def\\dmG{\\un{\\mathcal{G}}}\n",
"\\def\\dmK{\\un{\\mathcal{K}}}\n",
"\\def\\dmS{\\un{\\mathcal{S}}}\n",
"\\def\\dmC{\\un{\\mathcal{C}}}\n",
"\\def\\dmZ{\\un{\\mathcal{Z}}}\n",
"\\def\\bma{{\\mbox{\\boldmath $\\alpha$}}}\n",
"\\def\\bmb{{\\mbox{\\boldmath $\\beta$}}}\n",
"\\def\\bmu{{\\mbox{\\boldmath $\\mu$}}}\n",
"\\def\\bme{{\\mbox{\\boldmath $\\epsilon$}}}\n",
"\\def\\bmS{{\\mbox{\\boldmath $\\Sigma$}}}\n",
"\\def\\bmL{{\\mbox{\\boldmath $\\Lambda$}}}\n",
"\\def\\bmd{{\\mbox{\\boldmath $\\delta$}}}\n",
"\\def\\bmD{{\\mbox{\\boldmath $\\Delta$}}}\n",
"\\def\\bmG{{\\mbox{\\boldmath $\\Gamma$}}}\n",
"\\def\\bmphi{{\\mbox{\\boldmath $\\phi$}}}\n",
"\\def\\bmPhi{{\\mbox{\\boldmath $\\Phi$}}}\n",
"\\def\\bmpsi{{\\mbox{\\boldmath $\\psi$}}}\n",
"\\def\\bmtheta{{\\mbox{\\boldmath $\\theta$}}}\n",
"\\def\\eq{\\begin{equation}}\n",
"\\def\\eeq{\\end{equation}}\n",
"\\def\\i{{\\bf i}}\n",
"\\def\\un#1{{\\bf #1}}$$\n",
"\n",
"The *mean* of the random vector $\\un Z$ is the vector of mean values of $Z_1$ and $Z_2$,\n",
"\n",
"$$\n",
"\\langle \\un Z\\rangle = \\pmatrix{\\langle Z_1\\rangle \\cr \\langle Z_2\\rangle}.\n",
"$$\n",
"\n",
"The *covariance* of random variables $Z_1$ and $Z_2$ is a measure of how their realizations\n",
"are dependent upon each other and is defined to be the mean of the random variable\n",
"\n",
"$$(Z_1-\\langle Z_1\\rangle)(Z_2-\\langle Z_2\\rangle),$$\n",
"\n",
"i.e.,\n",
"\n",
"$$\n",
"\\cov(Z_1,Z_2) = \\left\\langle\\ (Z_1-\\langle Z_1\\rangle)(Z_2-\\langle Z_2\\rangle)\\ \\right\\rangle.\n",
"$$\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "7bdf519d-ff14-494a-9b96-e75819168109"
}
},
"source": [
"Two simple consequences of the definition of covariance are:\n",
"\n",
"$$\\eqalign{\n",
"\\cov(Z_1,Z_2) &= \\langle Z_1 Z_2\\rangle - \\langle Z_1\\rangle\\langle Z_2\\rangle \\cr\n",
"\\cov(Z_1,Z_1) &= \\var(Z_1).}\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "b542475d-2f68-4b44-af43-994d9c8ba068"
}
},
"source": [
"The *correlation* of $Z_1$ and $Z_2$ is defined by\n",
"\n",
"$$\n",
"\\rho_{12} = {\\cov(Z_1,Z_2)\\over\\sqrt{\\var(Z_1)\\var(Z_2)}}.\n",
"$$\n",
"\n",
"The correlation is unitless and restricted to values \n",
"\n",
"$$-1\\le \\rho_{12}\\le 1.$$ \n",
"\n",
"If $|\\rho_{12}|=1$, then $Z_1$ and $Z_2$ are *linearly dependent*."
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "7bab7569-1f77-4621-81d5-543180401b9e"
}
},
"source": [
"### Covariance matrix\n",
"\n",
"\n",
"Let $\\un a = (a_1,a_2)^\\top$\n",
"be any constant vector. Then the variance of the random variable\n",
"$\\un a^\\top\\un Z = a_1Z_1+a_2Z_2$ is given by\n",
"\n",
"$$\\eqalign{\n",
"\\var(\\un a^\\top \\un Z) &= \\cov(a_1Z_1+a_2Z_2,a_1Z_1+a_2Z_2)\\cr\n",
"&=a_1^2\\var(Z_1)+a_1a_2\\cov(Z_1,Z_2)+a_1a_2\\cov(Z_2,Z_1)+a_2^2\\var(Z_2)\\cr\n",
"&=(a_1,a_2) \\pmatrix{\\var(Z_1)&\\cov(Z_1,Z_2)\\cr\\cov(Z_2,Z_1)&\\var(Z_2)}\n",
" \\pmatrix{a_1\\cr a_2}.}\n",
"$$\n",
"\n",
"The matrix in the above equation is the *variance-covariance matrix* $\\bf\\Sigma$, i.e.,\n",
"\n",
"$$\n",
"{\\bf\\Sigma} = \\pmatrix{\\var(Z_1)&\\cov(Z_1,Z_2)\\cr\\cov(Z_2,Z_1)&\\var(Z_2)}.\n",
"$$\n",
"\n",
"Therefore\n",
"\n",
"$$\n",
"\\var(\\un a^\\top \\un Z) = \\un a^\\top\\bf\\Sigma\\un a.\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "e3363f19-45d0-44d1-94c4-d35c5bdf0a1c"
}
},
"source": [
"Note that $\\bf\\Sigma$ is *symmetric*, i.e.,\n",
"\n",
"$$\n",
"\\bf\\Sigma^\\top = \\bf\\Sigma\n",
"$$\n",
"\n",
"and *postive semi-definite*, that is, for any real vector $\\un a$, (we will show this later)\n",
"\n",
"$$\n",
"\\un a^\\top\\bf\\Sigma\\un a \\ge 0.\n",
"$$\n",
"\n",
"\n",
"Recall that $\\un a^\\top\\bf\\Sigma\\un a $ is called a *quadratic form*."
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "2127e01c-16cd-4c16-8e0f-517d0de560cd"
}
},
"source": [
"The covariance matrix can be written as an outer product:\n",
"\n",
"$$\n",
"\\bf\\Sigma=\\langle\\ (\\un Z-\\langle\\un Z\\rangle)(\\un Z-\\langle\\un Z\\rangle)^\\top\\ \\rangle =\n",
"\\langle\\un Z\\un Z^\\top\\rangle -\\langle\\un Z\\rangle\\langle\\un Z\\rangle^\\top.\n",
"$$\n",
"\n",
"For example\n",
"\n",
"$$\n",
"\\left\\langle\\pmatrix{Z_1-\\langle Z_1\\rangle\\cr Z_2-\\langle Z_2\\rangle} (Z_1-\\langle Z_1\\rangle,Z_2-\\langle Z_2\\rangle)\\right\\rangle\n",
"$$\n",
"\n",
"$$\n",
"=\\left\\langle \\pmatrix{(Z_1-\\langle Z_1\\rangle)^2 & (Z_1-\\langle Z_1\\rangle)(Z_2-\\langle Z_2\\rangle)\\cr\n",
" (Z_2-\\langle Z_2\\rangle)(Z_1-\\langle Z_1\\rangle) & (Z_2-\\langle Z_2\\rangle)^2 }\\right\\rangle\n",
"$$\n",
"\n",
"$$\n",
"= \\pmatrix{\\var(Z_1)&\\cov(Z_1,Z_2)\\cr\\cov(Z_2,Z_1)&\\var(Z_2)}\n",
"$$\n",
"\n",
"\n",
"If $\\langle\\un Z\\rangle=\\un 0$, we can write simply\n",
"\n",
"$$\n",
"\\bf\\Sigma=\\langle \\un Z\\un Z^\\top\\rangle.\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "c63f7111-69e2-4dc4-b41a-b069cc0648ba"
}
},
"source": [
"A random\n",
"vector $\\un Z=(Z_1,Z_2)^\\top$ is often described by a *multivariate normal\n",
"density function* $p(\\un z)$, given by\n",
"\n",
"$$\n",
"p(\\un z) = {1\\over (2\\pi)^{N/2}\\sqrt{|\\bf\\Sigma|}}\n",
"\\exp\\left(-{1\\over 2}(\\un z-\\bf\\mu)^\\top \\bf\\Sigma^{-1} (\\un z-\\bf\\mu)\\right),\n",
"$$\n",
"\n",
"in this case $N=2$.\n",
"\n",
"In analogy to the univariate case,\n",
"\n",
"$$\n",
"\\langle\\un Z\\rangle = \\bf\\mu,\\quad \n",
"\\langle\\ (\\un Z-\\langle\\un Z\\rangle)(\\un Z-\\langle\\un Z\\rangle)^\\top\\ \\rangle \n",
"= \\bf\\Sigma.\n",
"$$\n",
"\n",
"We write\n",
"$$\n",
"\\un Z \\sim \\mathcal{N}(\\bf\\mu,\\bf\\Sigma).\n",
"$$\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "acc1fcd9-07f1-476f-8977-f8fead4250e0"
}
},
"source": [
"**Theorem:**\n",
"\n",
"If two random variables $Z_1,Z_2$ have a bivariate normal distribution, they\n",
"are independent if and only if $\\rho_{12}=0$, that is, if and only if\n",
"they are uncorrelated.\n",
"\n",
"\n",
"In general a zero correlation does not imply that two random variables are independent. However this\n",
"theorem says that it does if the variables are normally distributed."
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "ae9d05b7-2f85-4e37-be17-03b40e63f1aa"
}
},
"source": [
"### Parameter estimation\n",
"\n",
"In the multivariate case, the sample functions of interest are those which can be used\n",
"to estimate the vector mean and variance-covariance matrix of a distribution\n",
"$P(\\un z)$. These are the *sample mean vector*\n",
"\n",
"$$\n",
"\\bar{\\un Z} = {1\\over n}\\sum_{i=1}^n\\un Z(i)\n",
"$$\n",
"\n",
"and the *sample variance-covariance matrix*\n",
"\n",
"$$\n",
"\\un S = {1\\over n-1}\\sum_{i=1}^n( \\un Z(i) - \\bar{\\un Z} ) (\\un Z(i) - \\bar{\\un Z})^\\top.\n",
"$$\n",
"\n",
"As in the scalar case, these are unbiased estimators:\n",
"\n",
"$$\n",
"\\langle\\bar{\\un Z}\\rangle = \\langle\\un Z\\rangle\\quad \\langle\\un S\\rangle = \\bf\\Sigma\n",
"$$\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "84469e9c-fe8b-4988-8e59-bf6d26ae8342"
}
},
"source": [
"If the random vectors $\\un Z(\\nu)$, $\\nu=1\\dots n$, are multivariate \n",
"normally distributed with mean $\\un \\mu$ and covariance matrix $\\bf\\Sigma$, then the sample mean vector\n",
"\n",
"$$\n",
"\\bar{\\un Z} = {1\\over n}\\sum_{\\nu=1}^n \\un Z(\\nu)\n",
"$$\n",
"\n",
"is multivariate normally distributed with mean $\\bf\\mu$ and covariance matrix ${\\bf\\Sigma}/n$.\n",
"\n",
"For zero-mean normal random vectors $\\un Z_i$, let\n",
"\n",
"$$\n",
"\\un X = (n-1)\\un S = \\sum_{\\nu=1}^n \\un Z(\\nu)\\un Z(\\nu)^\\top \n",
"$$\n",
"\n",
"The probability density function of $\\un X$ is\n",
"the *Wishart density with $n$ degrees of freedom*\n",
"\n",
"$$\n",
"p_W(\\un x) ={|\\un x|^{(n-N-1)/2}\\exp(-{\\rm tr}({\\bf\\Sigma}^{-1}\\un x)/2) \\over\n",
"2^{Nn/2}\\pi^{N(N-1)/4}|{\\bf\\Sigma}|^{n/2}\\prod_{i=1}^N\\Gamma[(n+1-i)/2]}\n",
"$$\n",
"\n",
"for $\\un x$ positive definite, and $0$ otherwise.\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "589337be-007f-487e-910c-b06c94eec3af"
}
},
"source": [
"**Exercise 1:**\n",
"\n",
"Show that the Wishart distribution with $n$ degrees of freedom\n",
"reduces to the chi-square distribution with $n$ degrees of freedom\n",
"in the univariate case $\\un Z \\to Z$ and ${\\bf\\Sigma}\\to\\sigma^2\\to 1$."
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "3908d012-4338-46b1-becd-9f8e2b9e64e8"
}
},
"source": [
"### Principal Components Analysis\n",
"\n",
"The principal components transformation generates linear combinations of multivariate\n",
"observations which have *maximum variance*.\n",
"\n",
"Consider a set of measurements represented by the random vector $\\un Z$\n",
"and assume that $\\langle\\un Z\\rangle=\\un 0$, so that\n",
"the covariance matrix is \n",
"\n",
"$$\\bf\\Sigma=\\langle\\un Z \\un Z^\\top\\rangle.$$\n",
"\n",
"We seek a linear combination\n",
"$Y = \\un a^\\top \\un Z$ whose variance is maximum. Remember\n",
"\n",
"$$\n",
"\\var(Y)=\\un a^\\top \\bf\\Sigma \\un a.\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "ddd79aae-e93a-4f08-82c9-9a576c32ca88"
}
},
"source": [
"The maximization only makes sense if we restrict $\\un a$ in some way.\n",
"A convenient constraint is $\\un a^\\top \\un a=1$.\n",
"So we maximize the Lagrange function\n",
"\n",
"$$\n",
"L = \\un a^\\top \\bf\\Sigma \\un a - \\lambda(\\un a^\\top \\un a - 1).\n",
"$$\n",
"\n",
"Taking the derivative,\n",
"\n",
"$$\n",
"{\\partial L \\over \\partial \\un a} = 2\\bf\\Sigma\\un a - 2\\lambda\\un a = \\un 0.\n",
"$$\n",
"\n",
"This is the eigenvalue problem\n",
"\n",
"$$\n",
"\\bf\\Sigma\\un a = \\lambda\\un a\n",
"$$\n",
"\n",
"for the symmetric, positive definite matrix $\\bf\\Sigma$.\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "29f72dea-3ce5-4686-b5da-9d1de6428e58"
}
},
"source": [
"Call the (orthogonal and normalized) eigenvectors $\\un a_1\\dots \\un a_N$.\n",
"Assume that they are sorted according to\n",
"decreasing eigenvalue \n",
"\n",
"$$\\lambda_1\\ge \\dots\\ge\\lambda_N.$$\n",
"\n",
"These eigenvectors are the\n",
"*principal axes* and the corresponding linear combinations $\\un a_i^\\top\\un Z$ are projections\n",
"along the principal axes, called the *principal components* of $\\un Z$.\n",
"\n",
"The individual principal components\n",
"\n",
"$$\n",
"Y_1 = \\un a_1^\\top\\un Z,\\ Y_2=\\un a_2^\\top\\un Z,\\ \\dots,\\ Y_N=\\un a_N^\\top\\un Z\n",
"$$\n",
"\n",
"can be expressed more compactly as a random vector $\\un Y$ by writing\n",
"\n",
"$$\n",
"\\un Y = \\un A^\\top\\un Z,\n",
"$$\n",
"\n",
"where $\\un A$ is the matrix whose columns comprise the eigenvectors, that is,\n",
"\n",
"$$\n",
"\\un A = (\\un a_1\\dots \\un a_N).\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "483e7e82-ffb9-40cb-aa44-f04ecfbc4315"
}
},
"source": [
"Since the eigenvectors are orthogonal and normalized, $\\un A$ is an orthonormal matrix:\n",
"\n",
"$$\n",
"\\un A^\\top \\un A=\\un I.\n",
"$$\n",
"\n",
"If the covariance matrix of the principal components vector $\\un Y$ is called $\\bf\\Sigma'$, then we have\n",
"\n",
"$$\n",
"\\bf\\Sigma' = \\langle \\un Y \\un Y^\\top \\rangle=\n",
"\\langle\\un A^\\top \\un Z \\un Z^\\top \\un A\\rangle\n",
"=\\un A^\\top \\bf\\Sigma \\un A =\n",
"\\pmatrix{\\lambda_1 & 0 & \\cdots &0\\cr\n",
" 0 &\\lambda_2& \\cdots&0\\cr\n",
" \\vdots&\\vdots&\\ddots&\\vdots\\cr\n",
" 0 & 0& \\cdots&\\lambda_N}\n",
"$$\n",
"\n",
"or\n",
"\n",
"$$\n",
"\\un A^\\top \\bf\\Sigma \\un A = \\bf\\Lambda\n",
"$$\n",
"\n",
"*The eigenvalues are thus seen to be the variances of the principal components, and all of the covariances are\n",
"zero.*"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "294ce2b1-38c1-4c27-b146-b1fc1591ead1"
}
},
"source": [
"The first principal component $Y_1$ has maximum variance \n",
"\n",
"$$\\var(Y_1)=\\lambda_1,$$ \n",
"\n",
"the second principal\n",
"component $Y_2$ has maximum variance\n",
"\n",
"$$\\var(Y_2)=\\lambda_2$$\n",
"\n",
"subject to the condition that it is uncorrelated\n",
"with $Y_1$, and so on.\n",
"The fraction of the total variance in the original dataset which\n",
"is accounted for by the first $r$ principal components is\n",
"\n",
"$$\n",
"{\\lambda_1+\\dots +\\lambda_r\\over\\lambda_1+\\dots +\\lambda_r+\\dots +\\lambda_N} = {\\lambda_1+\\dots +\\lambda_r \\over\\ {\\rm tr} \\bf\\Lambda}.\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "7b98c89d-9334-4215-8f54-85e8ea66dd65"
}
},
"source": [
"### Data design matrix \n",
"\n",
"Suppose that we have made independent\n",
"observations $\\un z(i)$ of $\\un Z(i)$, $i=1\\dots n$. These may be arranged\n",
"into an $n\\times \\texttt{}N$ matrix $\\dmZ$ in which each $N$-component observation vector\n",
"forms a row, i.e.,\n",
"\n",
"$$\n",
"\\dmZ = \\pmatrix{\\un z(1)^\\top \\cr \\un z(2)^\\top\\cr\\vdots\\cr\\un z(n)^\\top},\\quad\n",
"\\hbox{e.g. time series of soil moistures at several different depths}\n",
"$$\n",
"\n",
"This is a very useful construct for computer programs.\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "6a811c1e-06f6-4f68-b55d-f34244580ea2"
}
},
"source": [
"For two-dimensional observations\n",
"$$\n",
"\\un z(i) = \\pmatrix{z_1(i)\\cr z_2(i)} = (z_1(i), z_2(i))^\\top,\\quad i = 1\\dots n\n",
"$$\n",
"\n",
"Mean\n",
"$$\n",
"\\bar z_1 = {1\\over n}\\sum_{i=1}^n z_1(i),\\quad \\bar z_2= {1\\over n}\\sum_{i=1}^n z_2(i)\n",
"$$\n",
"\n",
"$$\n",
"\\bar{\\un z} = \\pmatrix{\\bar z_1 \\cr \\bar z_2} =\n",
"{1\\over n}\\pmatrix{z_1(1) & z_1(2) & \\cdots & z_1(n)\\cr\n",
" z_2(1) & z_2(2) & \\cdots & z_2(n)}\n",
"\\pmatrix {1\\cr 1\\cr \\vdots\\cr 1} = {1\\over n}\\dmZ^\\top\\un 1_n\n",
"$$\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "3265a9ea-3eea-4fda-8d3c-c63a0e61ade4"
}
},
"source": [
"Covariance matrix estimate\n",
"\n",
"$$\n",
"{\\bf s} = {1\\over n-1}\\pmatrix{\n",
"\\sum_i(z_1(i)-\\bar z_1)^2 & \\sum_i (z_1(i)-\\bar z_1)(z_2(i)-\\bar z_2) \\cr\n",
" \\sum_i (z_1(i)-\\bar z_1)(z_2(i)-\\bar z_2) & \\sum_i(z_2(i)-\\bar z_2)^2 }\n",
"$$\n",
"\n",
"Data matrix\n",
"\n",
"$$\n",
"\\dmZ =\\pmatrix{z_1(1) &z_2(1) \\cr\n",
" z_1(2) & z_2(2) \\cr\n",
" \\vdots & \\vdots \\cr\n",
" z_1(n) & z_2(n)}\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "7101c548-7372-41a3-93a7-315d98a19363"
}
},
"source": [
"*Column centered* data matrix\n",
"\n",
"$$\n",
"\\tilde\\dmZ =\\pmatrix{z_1(1)-\\bar z_1 & z_2(1) -\\bar z_2 \\cr\n",
" z_1(2)-\\bar z_1& z_2(2)-\\bar z_2 \\cr\n",
" \\vdots & \\vdots \\cr\n",
" z_1(n)-\\bar z_1 & z_2(n) -\\bar z_2}\n",
"$$\n",
"\n",
"So the covariance matrix estimate can be written as\n",
"\n",
"$$\n",
"\\un s = {1\\over n-1}\\tilde\\dmZ^\\top\\tilde\\dmZ\n",
"$$\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "ba1340f4-d0e1-4603-9cbc-adb97f64804d"
}
},
"source": [
"**Exercise 2:**\n",
"\n",
"(a) Show that the covariance matrix estimate can also be written in the form\n",
"\n",
"$$\n",
"(n-1)\\un s = \\dmZ^\\top\\un H\\dmZ,\n",
"$$\n",
"\n",
"where the symmetric *centering matrix* $\\un H$ is given by\n",
"\n",
"$$\n",
"\\un H = \\un I_{nn} - {1\\over n}\\un 1_n \\un 1_n^\\top.\n",
"$$\n",
"\n",
"(b) Show that the matrix $\\un H$ is *idempotent*, i.e.,\n",
"$$\n",
"\\un H \\un H = \\un H.\n",
"$$\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "09f1c402-6332-4515-ba62-cea364a6b79b"
}
},
"source": [
"Let $\\un x$ be any $n$-component vector. Then\n",
"\n",
"$$\n",
"\\un x^\\top\\un s\\un x = {1\\over n-1} \\un x^\\top\\dmZ^\\top\\un H\\dmZ\\un x =\n",
"{1\\over n-1} \\un x^\\top\\dmZ^\\top\\un H\\un H\\dmZ\\un x = {1\\over n-1}\\un y^\\top\\un y \\ge 0,\n",
"$$\n",
"\n",
"where $\\un y = \\un H\\dmZ\\un x$. Therefore $\\un s$ is positive semi-definite."
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "f0d7cb00-078d-4eec-ab36-d26fe324d93d"
}
},
"source": [
"\n",
"\n",
"So in practice, one estimates the covariance matrix $\\bf\\Sigma$ in terms of the data matrix $\\dmZ$,\n",
"and then solves the eigenvalue problem in the form\n",
"\n",
"$$\n",
"\\un s\\un a = {1\\over n-1}\\tilde\\dmZ^\\top\\tilde\\dmZ\\un a = \\lambda\\un a.\n",
"$$"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "55e3fc7a-31b2-4694-810d-89e776b861fb"
}
},
"source": [
"Alternatively, consider the SVD of the $m\\times N$ centered data matrix $\\tilde\\dmZ$:\n",
"\n",
"$$\\tilde\\dmZ = \\un U\\un W\\un V^\\top,\\quad \\un U^\\top\\un U = \\un V^\\top\\un V = \\un I,\\ \\un W\\hbox{ is diagonal}.$$\n",
"\n",
"Then \n",
"\n",
"$$\\eqalign{\n",
"(n-1)\\un s &= \\tilde\\dmZ^\\top\\tilde\\dmZ = \\un V\\un W\\un U^\\top\\un U\\un W\\un V^\\top\\cr\n",
"&= \\un V \\un W^2\\un V^\\top\n",
"}$$ \n",
"\n",
"or \n",
"\n",
"$$\\un V^\\top{\\un s}\\un V = {1\\over n-1}\\un W^2 = \\bf\\Lambda,$$\n",
"\n",
"so $\\un V$\n",
"is the matrix of eigenvectors and the eigenvalues are proportional to\n",
"the squares of the diagonal elements of W."
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "8b0316da-3e68-47d3-8a1a-e63d4a8672fa"
}
},
"source": [
"**Example:** (“Factor analysis”)\n",
"\n",
"We had for the principal components transformation\n",
"\n",
"$$\\un Y = \\un A^\\top\\un Z$$\n",
"\n",
"and we can recover the original variables by\n",
"inverting, \n",
"\n",
"$$\\un Z = (\\un A^\\top)^{-1}\\un Y = \\un A \\un Y.$$ "
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "6d3940f8-5152-442d-870d-0ade46d834b9"
}
},
"source": [
"Suppose\n",
"that the first $r$ PCs account for (explain) most of the variance in the\n",
"data and let $\\un A = (\\un A_r,\\un A_{r-})$, where\n",
"\n",
"$$\\un A_r = (\\un a_1,\\dots \\un a_r),\\quad \\un A_{r-} = (\\un a_{r+1},\\dots \\un a_N),$$\n",
"\n",
"and similarly \n",
"\n",
"$$\\un Y =\\pmatrix{\\un Y_r \\cr \\un Y_{r-}}.$$\n",
"\n",
"Now reconstruct $\\un Z$ from $\\un Y_r = (Y_1\\dots Y_r)^\\top$:\n",
"\n",
"$$\\un Z \\approx \\un A_r \\un Y_r.$$ \n"
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "e0e92efc-fd0d-4c3d-880b-9d8d310a1e59"
}
},
"source": [
"The *reconstruction error* is\n",
"\n",
"$$\\bf\\epsilon = \\un Z - \\un A_r \\un Y_r = \\un Z - \\un A_r \\un A_r^\\top \\un Z = (\\un I - \\un A_r \\un A_r^\\top)\\un Z = \\un A_{r-}\\un A_{r-}^\\top \\un Z,$$\n",
"\n",
"so we can write \n",
"\n",
"$$\\un Z = \\un A_r\\un Y_r + \\bf\\epsilon.$$ \n",
"\n",
"This is in the form\n",
"of a *factor analysis model*. In this case the “factors”\n",
"are the first $r$ principal components. The elements of $\\un A_r$ are\n",
"called the “factor loadings”."
]
},
{
"cell_type": "markdown",
"metadata": {
"nbpresent": {
"id": "c3de1d8c-967b-4f73-ba85-66359e49974d"
}
},
"source": [
"The variance-covariance matrix for the error term is \n",
"\n",
"$$\\eqalign{\n",
"\\langle \\bf\\epsilon\\bf\\epsilon^\\top\\rangle &= \\langle\\un A_{r-}\\un A_{r-}^\\top\\un Z\\un Z^\\top\\un A_{r-}\\un A_{r-}^\\top\\rangle \\cr\n",
"&= \\langle\\un A_{r-}\\un Y_{r-}\\un Y_{r-}^\\top\\un A_{r-}\\rangle \\cr\n",
"&= \\un A_{r-}\\un \\bf\\Lambda_{r-}\\un A_{r-}^\\top.}$$"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true,
"nbpresent": {
"id": "30092703-cda1-4e58-9272-ad2a287c737f"
}
},
"outputs": [],
"source": [
"%matplotlib inline"
]
},
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"collapsed": false,
"nbpresent": {
"id": "f060d030-9292-4c05-a1de-56d99e0919a6"
}
},
"outputs": [],
"source": [
"run dispms -f 20010525 -e 3 -p [4,5,6]"
]
},
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"collapsed": false,
"nbpresent": {
"id": "732faeb5-eed2-4b85-b609-fca9774add77"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"------------PCA ---------------\n",
"Wed Nov 9 11:40:54 2016\n",
"Input /home/mort/stats2016/20010525\n",
"Eigenvalues: [ 6.53264847e+03 3.94881303e+02 1.39378715e+02 3.23104634e+01\n",
" 1.48719152e+01 3.02456833e+00]\n",
"PCs written to: /home/mort/stats2016/20010525_pca\n",
"Reconstruction wrriten to: /home/mort/stats2016/20010525_recon\n",
"elapsed time: 5.69204521179\n"
]
}
],
"source": [
"run pca -r 1 /home/mort/stats2016/20010525"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false,
"nbpresent": {
"id": "ecfb019f-d658-4636-be62-1ec0529120df"
}
},
"outputs": [],
"source": [
"run dispms -f /home/mort/stats2016/20010525_pca -p [1,2,3] -e \\\n",
"-F /home/mort/stats2016/20010525_pca -P [4,5,6] -E 3 "
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false,
"nbpresent": {
"id": "72f98170-9688-4706-a990-2531583975ce"
}
},
"outputs": [],
"source": [
"run dispms -f /home/mort/stats2016/20010525 -p [4,5,6] -e 3 \\\n",
"-F /home/mort/stats2016/20010525_recon -P [4,5,6] -E 3 "
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": []
}
],
"metadata": {
"anaconda-cloud": {},
"kernelspec": {
"display_name": "Python [conda root]",
"language": "python",
"name": "conda-root-py"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 2
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython2",
"version": "2.7.12"
},
"nbpresent": {
"slides": {
"11947659-d16d-428b-8368-e8b8412e3eae": {
"id": "11947659-d16d-428b-8368-e8b8412e3eae",
"prev": "4f35efee-ea2c-407f-bd45-2daf200536e2",
"regions": {
"506a8458-7631-4d26-803c-69e0bcf07867": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "e0e92efc-fd0d-4c3d-880b-9d8d310a1e59",
"part": "whole"
},
"id": "506a8458-7631-4d26-803c-69e0bcf07867"
}
}
},
"21aec3db-26ed-4345-9daf-d13754118a0d": {
"id": "21aec3db-26ed-4345-9daf-d13754118a0d",
"prev": "2c1c1a12-6b0e-46c3-b4bf-11697ec47778",
"regions": {
"e09b2e6d-2060-48a3-b0c0-6ec511ad7258": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "e3363f19-45d0-44d1-94c4-d35c5bdf0a1c",
"part": "whole"
},
"id": "e09b2e6d-2060-48a3-b0c0-6ec511ad7258"
}
}
},
"22ad4351-faed-412f-9eda-37c3fcfab085": {
"id": "22ad4351-faed-412f-9eda-37c3fcfab085",
"prev": "c912caab-4faf-42bd-acc7-e1f835e31c6f",
"regions": {
"458006cb-be83-40a5-a638-f317777b6539": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "7101c548-7372-41a3-93a7-315d98a19363",
"part": "whole"
},
"id": "458006cb-be83-40a5-a638-f317777b6539"
}
}
},
"2883d525-69da-40f5-b8a2-18ec6c5a75fc": {
"id": "2883d525-69da-40f5-b8a2-18ec6c5a75fc",
"prev": "a0fd01fa-6330-492c-814b-233f6a2055f6",
"regions": {
"5dd43d98-2173-4cb9-8ac8-757b89a77716": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "29f72dea-3ce5-4686-b5da-9d1de6428e58",
"part": "whole"
},
"id": "5dd43d98-2173-4cb9-8ac8-757b89a77716"
}
}
},
"2c1c1a12-6b0e-46c3-b4bf-11697ec47778": {
"id": "2c1c1a12-6b0e-46c3-b4bf-11697ec47778",
"prev": "bdce7172-a12b-4c0a-81db-d39c96b293b5",
"regions": {
"eecb4957-cd2f-4c0d-8d4e-9128ae6992cf": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "7bab7569-1f77-4621-81d5-543180401b9e",
"part": "whole"
},
"id": "eecb4957-cd2f-4c0d-8d4e-9128ae6992cf"
}
}
},
"3d025bbf-7795-4ba1-8041-8189c1168e2e": {
"id": "3d025bbf-7795-4ba1-8041-8189c1168e2e",
"prev": "78d8feb0-3ad1-4d87-9c80-fe2e26c49f80",
"regions": {
"6cf36a5b-59d3-4edc-8077-4df31fd5aba0": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "8b0316da-3e68-47d3-8a1a-e63d4a8672fa",
"part": "whole"
},
"id": "6cf36a5b-59d3-4edc-8077-4df31fd5aba0"
}
}
},
"4590bdc5-61a6-413f-9f9c-b3a9646d7969": {
"id": "4590bdc5-61a6-413f-9f9c-b3a9646d7969",
"prev": "65e5ed40-126d-4c2c-bf18-63d2ea2868ac",
"regions": {
"89e69c13-5a54-4b88-8836-5b4d989fc525": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "3908d012-4338-46b1-becd-9f8e2b9e64e8",
"part": "whole"
},
"id": "89e69c13-5a54-4b88-8836-5b4d989fc525"
}
}
},
"4f35efee-ea2c-407f-bd45-2daf200536e2": {
"id": "4f35efee-ea2c-407f-bd45-2daf200536e2",
"prev": "3d025bbf-7795-4ba1-8041-8189c1168e2e",
"regions": {
"77e4b369-5306-4613-92f6-a6ac215b9dc5": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "6d3940f8-5152-442d-870d-0ade46d834b9",
"part": "whole"
},
"id": "77e4b369-5306-4613-92f6-a6ac215b9dc5"
}
}
},
"54dc7e1b-69fb-489d-bb84-b0bb489cdcce": {
"id": "54dc7e1b-69fb-489d-bb84-b0bb489cdcce",
"prev": "22ad4351-faed-412f-9eda-37c3fcfab085",
"regions": {
"3c2f5eab-15ba-43e6-80c2-63fcfd41f40a": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "ba1340f4-d0e1-4603-9cbc-adb97f64804d",
"part": "whole"
},
"id": "3c2f5eab-15ba-43e6-80c2-63fcfd41f40a"
}
}
},
"59811618-5c89-4a13-aacf-59a319dcc988": {
"id": "59811618-5c89-4a13-aacf-59a319dcc988",
"prev": "c17ab33e-3fac-4914-8183-3c889feadfb2",
"regions": {
"78ec879f-178b-43af-b248-436a002563ea": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "7b98c89d-9334-4215-8f54-85e8ea66dd65",
"part": "whole"
},
"id": "78ec879f-178b-43af-b248-436a002563ea"
}
}
},
"6030297c-6693-44ae-bd41-b677a63463c4": {
"id": "6030297c-6693-44ae-bd41-b677a63463c4",
"prev": "e2c3d9e5-d2a5-4cf9-ba3d-e21bbcd3526b",
"regions": {
"8bd4ce22-4579-4ae0-b0ae-5697e9297945": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "ae9d05b7-2f85-4e37-be17-03b40e63f1aa",
"part": "whole"
},
"id": "8bd4ce22-4579-4ae0-b0ae-5697e9297945"
}
}
},
"60dab116-d5f4-4be6-b808-f827fc9bba95": {
"id": "60dab116-d5f4-4be6-b808-f827fc9bba95",
"prev": "6030297c-6693-44ae-bd41-b677a63463c4",
"regions": {
"e581e4ac-1846-4444-9b5e-63759a00015c": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "84469e9c-fe8b-4988-8e59-bf6d26ae8342",
"part": "whole"
},
"id": "e581e4ac-1846-4444-9b5e-63759a00015c"
}
}
},
"656a1fac-64cd-403c-b6fc-9add01fd86ad": {
"id": "656a1fac-64cd-403c-b6fc-9add01fd86ad",
"prev": "cefac078-77e5-4af6-af35-b62c5fc99a7e",
"regions": {
"3dbb7190-9cd7-4115-b2a4-a7b91a320c21": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "7bdf519d-ff14-494a-9b96-e75819168109",
"part": "whole"
},
"id": "3dbb7190-9cd7-4115-b2a4-a7b91a320c21"
}
}
},
"65e5ed40-126d-4c2c-bf18-63d2ea2868ac": {
"id": "65e5ed40-126d-4c2c-bf18-63d2ea2868ac",
"prev": "60dab116-d5f4-4be6-b808-f827fc9bba95",
"regions": {
"34f506e8-1bf0-4ecc-979f-853bb81dd4e1": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "589337be-007f-487e-910c-b06c94eec3af",
"part": "whole"
},
"id": "34f506e8-1bf0-4ecc-979f-853bb81dd4e1"
}
}
},
"6ba5c7d2-18e1-4bbf-a68a-5f5e5a6d2b16": {
"id": "6ba5c7d2-18e1-4bbf-a68a-5f5e5a6d2b16",
"prev": "e2a9e902-b183-4fac-8773-0ef7107d5e34",
"regions": {
"2a52c530-f076-4898-ad47-64bbf50d8b8a": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "30092703-cda1-4e58-9272-ad2a287c737f",
"part": "whole"
},
"id": "2a52c530-f076-4898-ad47-64bbf50d8b8a"
}
}
},
"78d8feb0-3ad1-4d87-9c80-fe2e26c49f80": {
"id": "78d8feb0-3ad1-4d87-9c80-fe2e26c49f80",
"prev": "c2a148ec-a198-482a-abe2-3639d0eec6d3",
"regions": {
"61b704ab-1c30-4141-9599-c2845fd617c9": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "55e3fc7a-31b2-4694-810d-89e776b861fb",
"part": "whole"
},
"id": "61b704ab-1c30-4141-9599-c2845fd617c9"
}
}
},
"8696e028-5b4f-4736-b956-2f7fe9563edd": {
"id": "8696e028-5b4f-4736-b956-2f7fe9563edd",
"prev": "54dc7e1b-69fb-489d-bb84-b0bb489cdcce",
"regions": {
"8eb78f3f-9c7d-4ba3-a819-ff0972871801": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "09f1c402-6332-4515-ba62-cea364a6b79b",
"part": "whole"
},
"id": "8eb78f3f-9c7d-4ba3-a819-ff0972871801"
}
}
},
"a0fd01fa-6330-492c-814b-233f6a2055f6": {
"id": "a0fd01fa-6330-492c-814b-233f6a2055f6",
"prev": "4590bdc5-61a6-413f-9f9c-b3a9646d7969",
"regions": {
"eb863180-f91b-4e88-b88a-6513e036627f": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "ddd79aae-e93a-4f08-82c9-9a576c32ca88",
"part": "whole"
},
"id": "eb863180-f91b-4e88-b88a-6513e036627f"
}
}
},
"b5e178a9-a307-4150-b7c8-259ebbbf7d71": {
"id": "b5e178a9-a307-4150-b7c8-259ebbbf7d71",
"prev": "da729d36-de30-47bb-9a45-9663309dbb01",
"regions": {
"de26eed6-6aeb-416c-bd69-68821b83fc4f": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "ecfb019f-d658-4636-be62-1ec0529120df",
"part": "whole"
},
"id": "de26eed6-6aeb-416c-bd69-68821b83fc4f"
}
}
},
"bcb7352a-e52c-4853-ad7d-61e345f0038e": {
"id": "bcb7352a-e52c-4853-ad7d-61e345f0038e",
"prev": "6ba5c7d2-18e1-4bbf-a68a-5f5e5a6d2b16",
"regions": {
"773b90e6-a2e0-4b41-93bb-e876d8e703bb": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "f060d030-9292-4c05-a1de-56d99e0919a6",
"part": "whole"
},
"id": "773b90e6-a2e0-4b41-93bb-e876d8e703bb"
}
}
},
"bdce7172-a12b-4c0a-81db-d39c96b293b5": {
"id": "bdce7172-a12b-4c0a-81db-d39c96b293b5",
"prev": "656a1fac-64cd-403c-b6fc-9add01fd86ad",
"regions": {
"2dba09c5-9ed3-45d7-bcb3-fc7e52f0e9e3": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "b542475d-2f68-4b44-af43-994d9c8ba068",
"part": "whole"
},
"id": "2dba09c5-9ed3-45d7-bcb3-fc7e52f0e9e3"
}
}
},
"c17ab33e-3fac-4914-8183-3c889feadfb2": {
"id": "c17ab33e-3fac-4914-8183-3c889feadfb2",
"prev": "cbf1c043-ec8c-4103-8dc9-75f87274f276",
"regions": {
"e4433c3a-eb96-4a8c-9126-f18050a17208": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "294ce2b1-38c1-4c27-b146-b1fc1591ead1",
"part": "whole"
},
"id": "e4433c3a-eb96-4a8c-9126-f18050a17208"
}
}
},
"c217ce31-0567-4f07-91b1-ce8a9df113d8": {
"id": "c217ce31-0567-4f07-91b1-ce8a9df113d8",
"prev": "21aec3db-26ed-4345-9daf-d13754118a0d",
"regions": {
"5ef9fb6a-5168-4589-b3f9-127ce2f849c7": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "2127e01c-16cd-4c16-8e0f-517d0de560cd",
"part": "whole"
},
"id": "5ef9fb6a-5168-4589-b3f9-127ce2f849c7"
}
}
},
"c2a148ec-a198-482a-abe2-3639d0eec6d3": {
"id": "c2a148ec-a198-482a-abe2-3639d0eec6d3",
"prev": "8696e028-5b4f-4736-b956-2f7fe9563edd",
"regions": {
"44664e3c-93b6-4470-b251-4c788ba92256": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "f0d7cb00-078d-4eec-ab36-d26fe324d93d",
"part": "whole"
},
"id": "44664e3c-93b6-4470-b251-4c788ba92256"
}
}
},
"c6316dd0-626c-40e4-9aba-f6ff05e93817": {
"id": "c6316dd0-626c-40e4-9aba-f6ff05e93817",
"prev": "c217ce31-0567-4f07-91b1-ce8a9df113d8",
"regions": {
"19746a1f-56a5-4604-9c57-509d74e5cfd7": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "c63f7111-69e2-4dc4-b41a-b069cc0648ba",
"part": "whole"
},
"id": "19746a1f-56a5-4604-9c57-509d74e5cfd7"
}
}
},
"c912caab-4faf-42bd-acc7-e1f835e31c6f": {
"id": "c912caab-4faf-42bd-acc7-e1f835e31c6f",
"prev": "d0d23de0-de1c-45d0-8334-5a3ee516438e",
"regions": {
"4366eea7-a473-486d-b4d1-7f6a8fd0b097": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "3265a9ea-3eea-4fda-8d3c-c63a0e61ade4",
"part": "whole"
},
"id": "4366eea7-a473-486d-b4d1-7f6a8fd0b097"
}
}
},
"cbf1c043-ec8c-4103-8dc9-75f87274f276": {
"id": "cbf1c043-ec8c-4103-8dc9-75f87274f276",
"prev": "2883d525-69da-40f5-b8a2-18ec6c5a75fc",
"regions": {
"7620c04c-01d0-4645-adfd-de25b88c8f3c": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "483e7e82-ffb9-40cb-aa44-f04ecfbc4315",
"part": "whole"
},
"id": "7620c04c-01d0-4645-adfd-de25b88c8f3c"
}
}
},
"cefac078-77e5-4af6-af35-b62c5fc99a7e": {
"id": "cefac078-77e5-4af6-af35-b62c5fc99a7e",
"prev": null,
"regions": {
"32fb653b-ae21-45a1-9708-95a61f1a6af3": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "080858dc-1994-4cce-be1d-dc1538afa06c",
"part": "whole"
},
"id": "32fb653b-ae21-45a1-9708-95a61f1a6af3"
}
}
},
"d0d23de0-de1c-45d0-8334-5a3ee516438e": {
"id": "d0d23de0-de1c-45d0-8334-5a3ee516438e",
"prev": "59811618-5c89-4a13-aacf-59a319dcc988",
"regions": {
"8b1e01e9-efec-4351-813c-aabb81b02139": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "6a811c1e-06f6-4f68-b55d-f34244580ea2",
"part": "whole"
},
"id": "8b1e01e9-efec-4351-813c-aabb81b02139"
}
}
},
"da729d36-de30-47bb-9a45-9663309dbb01": {
"id": "da729d36-de30-47bb-9a45-9663309dbb01",
"prev": "bcb7352a-e52c-4853-ad7d-61e345f0038e",
"regions": {
"b6a67d3e-3a9f-4116-857e-dfb7251a9cb8": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "732faeb5-eed2-4b85-b609-fca9774add77",
"part": "whole"
},
"id": "b6a67d3e-3a9f-4116-857e-dfb7251a9cb8"
}
}
},
"e2a9e902-b183-4fac-8773-0ef7107d5e34": {
"id": "e2a9e902-b183-4fac-8773-0ef7107d5e34",
"prev": "11947659-d16d-428b-8368-e8b8412e3eae",
"regions": {
"dbd621c4-d1a2-4013-8347-7db6b73673eb": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "c3de1d8c-967b-4f73-ba85-66359e49974d",
"part": "whole"
},
"id": "dbd621c4-d1a2-4013-8347-7db6b73673eb"
}
}
},
"e2c3d9e5-d2a5-4cf9-ba3d-e21bbcd3526b": {
"id": "e2c3d9e5-d2a5-4cf9-ba3d-e21bbcd3526b",
"prev": "c6316dd0-626c-40e4-9aba-f6ff05e93817",
"regions": {
"9f5317af-b0d2-42f8-b50d-b55e6c130a36": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "acc1fcd9-07f1-476f-8977-f8fead4250e0",
"part": "whole"
},
"id": "9f5317af-b0d2-42f8-b50d-b55e6c130a36"
}
}
},
"e51544b2-fe54-454d-bd43-956d46dc9f2c": {
"id": "e51544b2-fe54-454d-bd43-956d46dc9f2c",
"prev": "b5e178a9-a307-4150-b7c8-259ebbbf7d71",
"regions": {
"f32d9970-5883-4b75-9bac-a50fcf03d168": {
"attrs": {
"height": 0.8,
"width": 0.8,
"x": 0.1,
"y": 0.1
},
"content": {
"cell": "72f98170-9688-4706-a990-2531583975ce",
"part": "whole"
},
"id": "f32d9970-5883-4b75-9bac-a50fcf03d168"
}
}
}
},
"themes": {
"default": "ac4c85e1-160e-41dc-be59-6791ae4a5482",
"theme": {
"ac4c85e1-160e-41dc-be59-6791ae4a5482": {
"id": "ac4c85e1-160e-41dc-be59-6791ae4a5482",
"palette": {
"19cc588f-0593-49c9-9f4b-e4d7cc113b1c": {
"id": "19cc588f-0593-49c9-9f4b-e4d7cc113b1c",
"rgb": [
252,
252,
252
]
},
"31af15d2-7e15-44c5-ab5e-e04b16a89eff": {
"id": "31af15d2-7e15-44c5-ab5e-e04b16a89eff",
"rgb": [
68,
68,
68
]
},
"50f92c45-a630-455b-aec3-788680ec7410": {
"id": "50f92c45-a630-455b-aec3-788680ec7410",
"rgb": [
155,
177,
192
]
},
"c5cc3653-2ee1-402a-aba2-7caae1da4f6c": {
"id": "c5cc3653-2ee1-402a-aba2-7caae1da4f6c",
"rgb": [
43,
126,
184
]
},
"efa7f048-9acb-414c-8b04-a26811511a21": {
"id": "efa7f048-9acb-414c-8b04-a26811511a21",
"rgb": [
25.118061674008803,
73.60176211453744,
107.4819383259912
]
}
},
"rules": {
"blockquote": {
"color": "50f92c45-a630-455b-aec3-788680ec7410"
},
"code": {
"font-family": "Anonymous Pro"
},
"h1": {
"color": "c5cc3653-2ee1-402a-aba2-7caae1da4f6c",
"font-family": "Lato",
"font-size": 8
},
"h2": {
"color": "c5cc3653-2ee1-402a-aba2-7caae1da4f6c",
"font-family": "Lato",
"font-size": 6
},
"h3": {
"color": "50f92c45-a630-455b-aec3-788680ec7410",
"font-family": "Lato",
"font-size": 5.5
},
"h4": {
"color": "c5cc3653-2ee1-402a-aba2-7caae1da4f6c",
"font-family": "Lato",
"font-size": 5
},
"h5": {
"font-family": "Lato"
},
"h6": {
"font-family": "Lato"
},
"h7": {
"font-family": "Lato"
},
"pre": {
"font-family": "Anonymous Pro",
"font-size": 4
}
},
"text-base": {
"font-family": "Merriweather",
"font-size": 4
}
}
}
}
}
},
"nbformat": 4,
"nbformat_minor": 0
}