Save and reuse settings of an analysis, example of Principal Component Analysis

Dataset for Principal Component Analysis (PCA) ARCHIVE76.4 KB

Tutorial video
Principal Component Analysis (PCA) is part of: Download Trial version More details See users' feedback
  • Pro Core statistical software

  • System configuration

    • Windows:
      • Versions: 9x/Me/NT/2000/XP/Vista/Win 7
      • Excel: 97 and later
      • Processor: 32 or 64 bits
      • Hard disk: 150 Mb
    • Mac OS X:
      • OS: OS X
      • Excel: X, 2004 and 2011
      • Hard disk: 150Mb.

Benefits

  • Easy and user-friendly
    Easy and user-friendly XLSTAT is flawlessly integrated with Microsoft Excel which is the most popular spreadsheet worldwide. This integration makes it one of the simplest available tools to work with as it utilizes the same philosophy as Microsoft Excel. The program is accessible in a dedicated XLSTAT tab. The analyses are grouped into functional menus. The dialog boxes are user-friendly and setting up an analysis is straightforward.
  • Data and results shared seamlessly
    Data and results shared seamlessly One of the greatest advantages of XLSTAT is the way you can share data and results seamlessly. As the results are stored in Microsoft Excel, anyone can access them. There is no need for the receiver to have an XLSTAT license or any additional viewer which makes your team-work easier and more affordable. In addition, results are easily integrable into other Microsoft Office software such as PowerPoint, so that you can create striking presentation in minutes.
  • Modular
    Modular XLSTAT is a modular product. XLSTAT-Pro is a core statistical module of XLSTAT which includes all the mainstream functionalities in statistics and multivariate analysis. More advanced features contained in add-on modules can be added for specific applications. This way you can adapt the software to your needs making the software more cost-efficient.
  • Didactic
    Didactic The results of XLSTAT are organized by analysis and are easy to navigate. Moreover useful information is provided along with the results to assist you in your interpretation.
  • Affordable
    Affordable XLSTAT is a complete and modular analytical solution that can suit any analytical business needs. It is very reasonably priced so that the return of your investment is almost immediate. Any XLSTAT license comes with top level support and assistance.
  • Accessible - Available in many languages
    Accessible - Available in many languages We have ensured XLSTAT is accessible to everyone by making the program available in many languages, including Chinese, English, French, German, Italian, Japanese, Polish, Portuguese and Spanish.
  • Automatable and customizable
    Automatable and customizable Most of the statistical functions available in XLSTAT can be called directly from the Visual Basic window of Microsoft Excel. They can be modified and integrated to more code to fit to the specificity of your domain. Adding tables and plots as well as modifying existing outputs becomes easy. Furthermore, XLSTAT includes some special tools on the dialog boxes to generate automatically the VBA code in order to reproduce your analysis using the VBA editor or to simply load pre-set settings. This effortless automation of routine analysis will be a huge time saver on your part.

Datasets for saving and reusing VBA codes

Two Excel workbooks with both the data and the results can be downloaded by clicking here. The data used is the process of food measurements samples.

Generating the settings to reuse

We are going to create a Principal component analysis template on one dataset and use it on the second.

Open the first file called Automation_1.xls.

Enabling advanced options

Once XLSTAT-Pro is activated, go to the menu Options, and in the tab Advanced enable the option named Show the advanced buttons in the dialog boxes.

Principal Component Analysis

Setting up an analysis - example of Principal Component Analysis

Then select the XLSTAT / Analyzing data / Principal components analysis command, or click on the corresponding button of the Analyzing Data toolbar (see below).

Principal Component AnalysisPrincipal Component Analysis software

In the General tab, set the following:

  • Observations/variables table: Columns B to G
  • Data format: Observations/variables table
  • PCA type: Pearson (n)
  • Variable labels: enabled
  • Observation labels: ticked and select the column A for the sample name
  • Sheet: chosen to display the results in a new sheet

Principal Component Analysis software

Go to the next tab Options. For the option Filter factors, choose Maximum number and set the value to six. This way all the components will be calculated.

Principal Component Analysis in Excel

Go to the tab Outputs. Here we want to get a synthetic report so we will only select the following:

  • Eigenvalues,
  • Factor Loadings,
  • Variables/Factors correlations,
  • Factor scores.

Principal Component Analysis package

Finally we are going to use all three plots that can be selected in the Charts tab:

  • Correlation charts
  • Observations charts
  • Biplots

Principal Component Analysis tools

Now we have specified all the settings we will save the code to be reused.

Generating and saving the settings to be reused

Click on the red button at the bottom left of the dialog box.

Principal Component Analysis with MS Excel

Save the code under a name that is easy for you to remember, for example in this case we use "PCArecipe1".

Principal Component Analysis PCA

Press OK to launch the analysis.

Results of the Principal Component Analysis

Choose the plot for the axes F1 and F2 by clicking Select, then change the selection to Abscissa F3 and Ordinates F4. Once you have completed this, simply click again on Select and then press Done.

Principal Component Analysis tutorial

Take a look at the biplot (shown below).

Principal Component Analysis software Excel

This process is usually to be stable so we can expect little variation. You can see that all the samples are centered tidily around the middle of the plot.

Reusing the settings

Now open the second file Automation_2.xls

Go to the menu Analyzing data / Principal Component Analysis and when the dialog box is open click on the blue button to load the code.

Principal Component Analysis

Select the code "PCArecipe1.txt".

The settings are automatically established. So now simply click on Continue and have a look at the biplot.

Principal Component Analysis biplot

This time one of the samples seems to be further away than the other samples. The sample 13 may be an outlier.

Have a look at this video to see how to save and reuse the parameters of an analysis in XLSTAT.