Amazing video! straight to the point, well explained without all the mathematical mumbo jumbo. Indians are the best !! I always end up on an indian tutorial. Greets from Mexico
@asifmolbioАй бұрын
Thanks for generous message. By the way i am from Pakistan 🇵🇰
@hayatelish97515 ай бұрын
Amazing video
@asifmolbio5 ай бұрын
Glad you like it
@hamzaahmed92272 жыл бұрын
Thanks for all those valuable data.
@asifmolbio2 жыл бұрын
Glad it was helpful!
@samkhan75362 жыл бұрын
Nice lecture, keep it up
@asifmolbio2 жыл бұрын
Glad you like it
@sanjaisrao484 Жыл бұрын
Thanks, lkeep uploading
@asifmolbio Жыл бұрын
Sure, Glad you like it
@uzmainayat99527 ай бұрын
Which values are being used to generate pca1 or Pc2 and so on .. plz use one example for gene expression data . Calculation video is very clear . Thanks
@asifmolbio7 ай бұрын
I can explain how PCA (Principal Component Analysis) works and demonstrate the calculation of the first principal component (PC1) using a simple example with gene expression data. Step-by-Step PCA Calculation Standardize the Data: The first step in PCA is to standardize the data so that each gene expression level has a mean of 0 and a standard deviation of 1. Covariance Matrix Calculation: Compute the covariance matrix to understand how the genes vary with respect to each other. Eigenvalues and Eigenvectors: Calculate the eigenvalues and eigenvectors of the covariance matrix. The eigenvectors represent the directions of maximum variance (principal components), and the eigenvalues represent the magnitude of these variances. Principal Components: Project the original data onto the eigenvectors to get the principal components. Example with Gene Expression Data Assume we have a simple dataset with gene expression levels for 3 genes (Gene1, Gene2, Gene3) across 3 samples. Sample Gene1 Gene2 Gene3 S1 2.5 2.4 1.0 S2 0.5 0.7 2.0 S3 2.2 2.9 0.5 Step 1: Standardize the Data First, calculate the mean and standard deviation for each gene. Mean of Gene1 = (2.5 + 0.5 + 2.2) / 3 = 1.733 Mean of Gene2 = (2.4 + 0.7 + 2.9) / 3 = 2.0 Mean of Gene3 = (1.0 + 2.0 + 0.5) / 3 = 1.167 Standardize each gene expression value: For Gene1: S1 = 2.5 − 1.733 Var(Gene1) S1= Var(Gene1) 2.5−1.733 S2 = 0.5 − 1.733 Var(Gene1) S2= Var(Gene1) 0.5−1.733 S3 = 2.2 − 1.733 Var(Gene1) S3= Var(Gene1) 2.2−1.733 For simplicity, let’s assume standard deviations are calculated as follows: Var(Gene1) = ( ( 2.5 − 1.733 ) 2 + ( 0.5 − 1.733 ) 2 + ( 2.2 − 1.733 ) 2 ) / ( 3 − 1 ) ((2.5−1.733) 2 +(0.5−1.733) 2 +(2.2−1.733) 2 )/(3−1) Var(Gene2) = ( ( 2.4 − 2.0 ) 2 + ( 0.7 − 2.0 ) 2 + ( 2.9 − 2.0 ) 2 ) / ( 3 − 1 ) ((2.4−2.0) 2 +(0.7−2.0) 2 +(2.9−2.0) 2 )/(3−1) Var(Gene3) = ( ( 1.0 − 1.167 ) 2 + ( 2.0 − 1.167 ) 2 + ( 0.5 − 1.167 ) 2 ) / ( 3 − 1 ) ((1.0−1.167) 2 +(2.0−1.167) 2 +(0.5−1.167) 2 )/(3−1) Standardized data (assuming standard deviations are 1 for simplicity): Sample Gene1 Gene2 Gene3 S1 0.767 0.4 -0.167 S2 -1.233 -1.3 0.833 S3 0.467 0.9 -0.667 Step 2: Covariance Matrix Calculation Calculate the covariance matrix for the standardized data. Cov = ( Var(Gene1) Cov(Gene1, Gene2) Cov(Gene1, Gene3) Cov(Gene2, Gene1) Var(Gene2) Cov(Gene2, Gene3) Cov(Gene3, Gene1) Cov(Gene3, Gene2) Var(Gene3) ) Cov= ⎝ ⎛ Var(Gene1) Cov(Gene2, Gene1) Cov(Gene3, Gene1) Cov(Gene1, Gene2) Var(Gene2) Cov(Gene3, Gene2) Cov(Gene1, Gene3) Cov(Gene2, Gene3) Var(Gene3) ⎠ ⎞ Step 3: Eigenvalues and Eigenvectors Compute the eigenvalues and eigenvectors of the covariance matrix. Step 4: Principal Components Project the standardized data onto the eigenvectors. For simplicity, let's assume the eigenvectors (principal components) are: PC1 = ( 0.5 0.5 − 0.7 ) PC1= ⎝ ⎛ 0.5 0.5 −0.7 ⎠ ⎞ Calculation of PC1 Calculate the projection of each sample on PC1: PC1 ( S1 ) = 0.5 × 0.767 + 0.5 × 0.4 − 0.7 × ( − 0.167 ) = 0.3835 + 0.2 + 0.1169 = 0.7004 PC1(S1)=0.5×0.767+0.5×0.4−0.7×(−0.167)=0.3835+0.2+0.1169=0.7004 PC1 ( S2 ) = 0.5 × ( − 1.233 ) + 0.5 × ( − 1.3 ) − 0.7 × 0.833 = − 0.6165 − 0.65 − 0.5831 = − 1.8496 PC1(S2)=0.5×(−1.233)+0.5×(−1.3)−0.7×0.833=−0.6165−0.65−0.5831=−1.8496 PC1 ( S3 ) = 0.5 × 0.467 + 0.5 × 0.9 − 0.7 × ( − 0.667 ) = 0.2335 + 0.45 + 0.4669 = 1.1504 PC1(S3)=0.5×0.467+0.5×0.9−0.7×(−0.667)=0.2335+0.45+0.4669=1.1504 So, the values of PC1 for the samples S1, S2, and S3 are approximately 0.7004, -1.8496, and 1.1504, respectively. Summary The process involves standardizing the data, calculating the covariance matrix, finding eigenvalues and eigenvectors, and projecting the data onto the principal components. This projection yields the principal component scores (e.g., PC1 values) for each sample.
@uzmainayat99527 ай бұрын
I HAVE LOG FOLD CHANGE VALUE . FOR GENES AS ROWS AND SAMPLES ON COLUMNS WITH OTHER PARAMETERS LIKE FOLD CHANGE ,P ADJSUTED VALUE ETC . hOW CAN I ANALYZE THIS TYPE OF DATA
@nehasheoran9 ай бұрын
great video really helped put a lot. please keep uploading more transcriptome analyses videos
@asifmolbio9 ай бұрын
Glad if its helping
@4Getf00l Жыл бұрын
As salam alikum Dr. Asif, thank you for the explanation of the PCA.I have two questions- 1. I have three treatments in my RNA seq data (heat, ABA and Cold) , and I have raw data from the company, how can I do the PCA analysis ? Do you recommend any software? is it possible to do it using Shiny GO or iDEP? (I followed your tutorial for shiny GO and presented the data to my professor yesterday, and he was happy to see the interesting results it revealed, Jazakillahi Khairan. ) 2. In the video at 6:23, in the second scree plot, I see a descending order of PCA values from PC1 to PC10, like you explained it should be, however, I see the circular dots from the top of PC1 in a rising manner , what does that indicate?
@asifmolbio Жыл бұрын
Wslam, Glad if it’s helping scientific community. 1. Yes iDEP can be used for PCA for details please see videos related to iDEP. 2. Circular dots are only showing the trend of data values. However, these dots are not of great value for PCA interpretation. Most important are PC1 and PC2, as these should be higher and higher. As, much these both are higher, it show this much variations are due tở treatment applied under study.
@Hameedenv727 ай бұрын
Thanks a lot for good work
@asifmolbio7 ай бұрын
Glad you like it
@kaihu5408 Жыл бұрын
what does inversely related treatment mean according to the pca ?
@asifmolbio Жыл бұрын
It means applying (increasing) Treatment is decreasing set of gene expressions and vice versa.
@saraaiman89765 ай бұрын
Which analysis is best Correlation or PCA??
@asifmolbio5 ай бұрын
Both have different purpose and own importance
@saraaiman89765 ай бұрын
@@asifmolbio i have 13 different treatments with 19 variables
@saraaiman89765 ай бұрын
13 different treatments are actually different extract from different plants
@mushtaqnajar89302 жыл бұрын
Dear Dr.ASIF, please make video tutorials on , how to do proteomic and metabolomics data analysis. Followed you on twitter, love your style of teaching
@asifmolbio2 жыл бұрын
Sure dear mushtaq , thanks for following and your like , i will record a video on metabolome analysis soon
@sanjaisrao484 Жыл бұрын
Please upload more like this, please
@asifmolbio Жыл бұрын
Sure stay tuned
@kaihu5408 Жыл бұрын
Thanks for your video, but your understanding of PCA is very different from what I learned, if pc1+pc2 is 47%, it means that the first two pc can only explain 47% of the total variation, not that treatment accounts for 47% of the variation. And how come the number of pc are related to the number of treatments? they are supposed to be created with linear combination of the expression of all genes?
@asifmolbio Жыл бұрын
Thanks for sending message, my intended mean was the same as you said, under given dataset (example quoted) 47 percent for given rna seq treatments. Yes, we use linear combination of gene experiments and use original variable to generate the axes.
@fatihfaiqa22 жыл бұрын
Thank you Dr. Asif for explaining about PCA. I have rna seq data which showing PC1 is >95% while PC2
@asifmolbio2 жыл бұрын
Glad you like it. Results and treatments you made are good.
@Beautifullife7189 Жыл бұрын
Sir pca data input in software
@asifmolbio Жыл бұрын
Sure will upload soon
@samrawitgebeyehu7648 Жыл бұрын
Thanks, Dr. I did PCA to see the genetic relatedness of breeds, and I found that PC1 is 21.6% and PC2 3.94%; I wonder about the interpretation.
@asifmolbio Жыл бұрын
Component 1 is contributing 21 percent to relatedness while component 2 only 3.94 %
@samrawitgebeyehu7648 Жыл бұрын
One other question, who could I consider PC3 in the analysis?
@asifmolbio Жыл бұрын
Your PC2 is already low (3 %), no need to consider pc3 as it would be even more low
@samrawitgebeyehu7648 Жыл бұрын
@@asifmolbio Thank you so much🙏
@samrawitgebeyehu7648 Жыл бұрын
@@asifmolbio Is there any consideration that we could know the reason for such a lower contribution?
@sikandarshah7326 Жыл бұрын
Aoa sir please share endnote latest version. I need it for my thesis... Reply to my email please
@asifmolbio Жыл бұрын
I have endnote 7 if you need
@sikandarshah7326 Жыл бұрын
@@asifmolbio yes sir please share
@sikandarshah7326 Жыл бұрын
R/Sir, is it compatible for apa7
@asifmolbio Жыл бұрын
You can try i will share by tomorrow
@sikandarshah7326 Жыл бұрын
@@asifmolbio thank you so much sir. You are 👍👍👍👍👍 great