OriginLab Corporation - Data Analysis and Graphing Software - 2D graphs, 3D graphs, Contour Plots, Statistical Charts, Data Exploration, Statistics, Curve Fitting, Signal Processing, and Peak Analysis     
 
Skip Navigation Links
All BooksExpand All Books
TutorialsExpand Tutorials
Data AnalysisExpand Data Analysis
Batch ProcessingExpand Batch Processing

4.8.4 Batch Processing with Word Template for Reporting

Summary

Origin can perform batch analysis of multiple files and output cell-linked analysis results to an external Word template for reporting.

Minimum Origin Version Required: Origin 2016 SR0

What you will learn

This tutorial will show you how to:

  • Add bookmarks from a Word template to a specific Analysis Template
  • Link analysis results to bookmarked cells in Word template and adjust the sizes of graphs to be exported
  • Sending one time results to Word template for reporting
  • Perform batch analysis of multiple files and export results to Word/PDF files

Steps

In this tutorial we will use a built-in Word template Sensor Analysis Report.dotx which is located at <Origin EXE folder>\Samples\Batch Processing\ folder. To view the bookmark labels on the Word template, with the file open go to File: Options to open Word Options dialog. Then select Advanced on the left panel and scroll down to section Show document content on the right panel and check Show bookmarks checkbox there.

Batch Processing with Word Template for Reporting 01a.png

Add Bookmarks to Analysis Template

  1. Go to menu File: Open and browse to <Origin EXE folder>\Samples\Batch Processing\ folder, select file Sensor Analysis.ogw to open it.
  2. Activate worksheet Data, click button Button Import ASCII.png and browse to <Origin EXE folder>\Samples\Curve Fitting\ folder and select file Sensor01.dat to import data for analysis.
  3. Go to menu File: Add Word Bookmarks to Analysis Template... to open dialog. Click the browser button Tutorial Import 005.png to the right of the Word template box and browse to <Origin EXE folder>\Samples\Batch Processing\ folder to select Sensor Analysis Report.dotx.
  4. Click to select all bookmark entries in Bookmarks list under Select Bookmarks node and click OK button to add those bookmark entries to active analysis template.
Batch Processing with Word Template for Reporting 01.png

Link Analysis Results to Word Template

  1. Right click cell next to FileName bookmark in Links column (Long Name) and select Insert Variable.
  2. In appeared dialog, click Info tab and select FILEName under SYSTEM.IMPORT treenode. Click Insert button to insert it.
  3. Do the same to insert info variable for bookmark FileDate. To make it display as normal date, right click that cell and select Format Cells.
  4. Select Date from Format drop-down list and click OK button to close dialog.
  5. For graph bookmark FittedGraph, right click the cell in Links column (Long Name) in newly generated worksheet Bookmarks to select Insert Graph to open dialog. In appeared dialog, click the browser button Tutorial Import 005.png to the right of the Graphs box to open Graph Browser dialog. Check Show Embedded Graph checkbox on the bottom left to make embedded graphs available in panel on the left. Click to select desired graph and add it to panel on the right. Click OK to insert graph to Bookmarks worksheet.
Batch Processing with Word Template for Reporting 02.png
Then input graph width for instance 250, in unit of points in GraphWidth (Long Name) column to adjust the size of graph exported to Word report.

6. Do the same to insert graph for bookmark ResidualPlot.

7. For bookmarks related to parameter values, you can copy and paste values as link from report sheet. To do it, click report sheet Linear Fit of Data B "Sensor Output" and locate the Parameters table. Click the corresponding data cell and right click to select Copy. Return to Bookmarks sheet, right click desired cell in Links column and select Paste Link to build the connection between bookmarks in Word template and values in report sheet.

8. Repeat this "Copy and Paste Link" operation to fill in the rest of bookmark links. When done, select menu File: Save Workbook as Analysis Template... to save the analysis template as Sensor Analysis Template.ogw .

Batch Processing with Word Template for Reporting 04.png

You can follow the steps in the previous tutorial "Creating a Custom Report Sheet" to learn how to copy and paste results as link to desired cell.

Sending One Time Results to Word Template to Create Word Report

Sometimes we may just want to analyze one data file and quickly create one Word report. Continue from the example above, suppose we have all results linked to Word bookmarks as shown in Bookmarks worksheet, to create an one time Word report for active sheet you can simply click Export to Word button Button Create Word Report.png on the top left corner to create it.

You can further specify where to output the Word report in appeared Export Path dialog.

Batch Process and Export Results to Word/PDF Files

  1. Start with a new project.
  2. Click on the Batch Processing button Button Batch Processing.png.
  3. Make sure Load Analysis Template is selected as Batch Processing Mode. In the Analysis Template drop-down, select the Sensor Analysis Template.ogw file we created earlier (you may need to click the button to the right of the list and browse to the created file).
  4. Select PDF from Export to drop-down list to export report as PDF file.
  5. Click the browser button Tutorial Import 005.png to the right of the Word template box and browse to <Origin EXE folder>\Samples\Batch Processing\ folder to select Sensor Analysis Report.dotx.
  6. Optionally you can click browser button Tutorial Import 005.png on the right of Export Path to specify another path for export.
  7. Click on the Browse button Tutorial Import 005.png in the File List section and select the Sensor01.dat, Sensor02.dat and Sensor03.dat from the <Origin EXE Folder>\Samples\Curve Fitting folder.
  8. Click Add File(s), then click OK.
  9. Select File Name as Dataset Identifier.
  10. Make sure the Data Sheet drop-down is set as Data.
  11. Make sure the Result Sheet drop-down is set as Result.
  12. Make sure that Delete Intermediate Workbook is cleared.
Batch Processing with Word Template for Reporting 05.png

The location of exported PDF files was outputted to Message Log.

A sample of exported PDF version report is as following:

Batch Processing with Word Template for Reporting 07.png
 

© OriginLab Corporation. All rights reserved.