|
|
|
|
|
|
|
|
Home > Blog
|
|
|
4/8/2009
As part of the next Inference release, we've started working on Inference in PowerPoint. Similar to Inference in Word, Inference in PowerPoint will enable you to assemble dynamic Microsoft PowerPoint presentations containing your data, MATLAB objects, MATLAB code, and text annotations (commentary). When executed, Inference in PowerPoint will run your MATLAB code and generate a Results Document presentation that contains textual, numerical and graphic output of scripting commands in addition to formatted text annotations.
The next Inference release is due out this summer. Here's a screenshot of our latest build:
If you have any thoughts as to what you'd like to see in the Inference in PowerPoint module, feel free to comment to this blog post or shoot me an email at development@bluereference.com. 3/3/2009
One of the features that we added to the most recent release of Inference is the ability to print Expression output to the header and footer regions of Microsoft Word documents. I recently created a sample How-To Guide that illustrates dynamic header and footer output in an Inference in Word document. If you have Inference for MATLAB installed, you can download the How-To Guide, entitled "Header and Footer Output in Word," from Inference Online:
To print output to headers and footers:
- Create an Expression that returns a value.
- Enter a Label for the Expression – for example, MyExpression.
- In a header or footer, type the Label of the Expression (enclosed in greater than/less than brackets). Example: <MyExpression>.
When the document is executed, the bracketed Expression label placeholders will be replaced with the actual code output from the Expression.
Here are some additional tips:
- You can use the Output Result property of the Expression to specify whether the Expression gets evaluated in the Word canvas during document execution. This restricts the expression output to only the header or footer.
- You can use the Alias Code Text property of the Expression to specify whether the code, or the label, is shown in the Word canvas for an Expression. This makes the Word canvas easier to read.
- If your document includes a Data Frame, you can use an Expression to access its attributes. For example, if your DataFrame includes a title or version number, you can include that in the header/footer of your results document.
- Header/footer output will also be included in pdf results documents.
- This same functionality also works in Excel.
In the actual How-To Guide, we create two Expressions that will generate the header and footer output, and then add the placeholders into the header and footer areas of the document:
When the document is executed to a Microsoft Word View, the Expressions are evaluated, and their output replaces those placeholders in the header and footer sections:
That's pretty much it. You can download this How-To Guide from Inference Online and try it out yourself! 2/18/2009
Inference in Word supports the capture of HTML files that are generated during code execution. These HTML files are then embedded into the Results Document during document execution. The key to this process is letting Inference provide the path to where the target HTML file is generated. This is done with a built-in Inference function:
infOutput_getHTMLFilePath()
I recently created a sample How-To Guide that illustrates capturing HTML file output in an Inference in Word document. If you have Inference for MATLAB installed, you can download the How-To Guide, entitled "Output HTML Tables," from Inference Online:
The Example
In this How-To Guide, I created some sample tabular data, and then used a custom function to create an HTML file. This HTML file then gets embedded in the executed Results Document.
To begin, I located a custom function in the MATLAB Central File Exchange called cell2html:
http://www.mathworks.com/matlabcentral/fileexchange/4874
This function takes a MATLAB cell array as input and outputs an HTML file to a specified path. I embedded this M-file as an embedded object within my Inference in Word document:
Next, I added some code to create a sample MATLAB cell array:
Then, I simply called the cell2html function and used the return value from the infOutput_getHTMLFilePath function as the specified path:
When I execute this document to a Microsoft Word View…
…the tabular data is shown as an HTML table in a new Microsoft Word document:
That's all there is to it. Download this document from Inference Online and try it out yourself! 2/16/2009
One of the most requested usability improvements for Inference for MATLAB was the addition of keyboard shortcuts. In essence, users want to be able to build and edit documents more quickly using just the keyboard. Towards that end, we added a number of new keyboard shortcuts into the recent commercial release of Inference for MATLAB:
Word/Excel Shortcuts
While in Word and Excel, you can use the following keyboard shortcuts combinations:
- CTRL-ALT-SHIFT + F1: Launch Inference Online
- CTRL-ALT-SHIFT + F2: Add Parts Container to the current document
- CTRL-ALT-SHIFT + F3: Toggle Taskpane Visibility
- CTRL-ALT-SHIFT + F4: Insert a new Code Block
- CTRL-ALT-SHIFT + F5: Insert and Edit a new Code Block
- CTRL-ALT-SHIFT + F6: Insert a new Expression
- CTRL-ALT-SHIFT + F7: Insert and Edit a new Expression
- CTRL-ALT-SHIFT + F8: Edit the selected code item (Code Block or Expression)
- CTRL-ALT-SHIFT + F9: Edit the Parts Container in Inference Studio
- CTRL-ALT-SHIFT + F10: Export to Word/Excel View
- CTRL-ALT-SHIFT + F11: Export to Webpage View
- CTRL-ALT-SHIFT + F12: Export to PDF View (Note: This only works with Office 2007, and if you have installed the Export to PDF or XPS add-in for Office 2007)
Code Editor Shortcuts
While in the Code Editor, you can use the following keyboard shortcut combinations:
- CTRL-ALT + ENTER: Close the Code Editor window; this is the same as clicking the OK button
- CTRL + TAB: This moves the tabstop to the next control; this is useful for tabbing out of the code editor, and then allows you to tab around the form
- CTRL + A: This selects all the text inside of the Code Editor.
What's up with the triple CTRL-ALT-SHIFT key combinations you ask? One of the interesting challenges in implementing the keyboard shortcuts was finding open key combinations that were not in use by Word and Excel already. This is what eventually led to the use of the CTRL-ALT-SHIFT + Function-Key implementation. 2/11/2009
Inference for MATLAB attempts to determine the location of your MATLAB installation by querying the Windows registry. When MATLAB installs on 64-bit machines, it installs a genuine 64-bit application, and thus creates its installation path entries in the 64-bit section of the Windows registry. However, Inference is compiled as a 32-bit application to run with Microsoft Office (itself only a 32-bit application). This means that Inference cannot access the 64-bit MATLAB installation registry entries to determine where your MATLAB installation is located.
Confusing? You betcha! J The bottom line is that if you have a 64-bit MATLAB installation, the first time you try to execute an Inference document you will likely receive an error screen that looks like this:
As the error message indicates, the solution to this is to manually specify the MATLAB path. To do this, open Microsoft Word, and from the Inference ribbon tab (Office 2007) or the Inference menu (Office 2003), select Options:
In the ensuing Inference Options dialog, select Scripting Platforms from the left-hand bar:
…and check the checkbox Specify the location of the platform installation:
Next, click the Browse button and navigate to the folder that contains your actual MATLAB installation. In my case, the path is C:\Program Files\MATLAB\R2007b:
Click OK to close the Inference Options dialog. The next time you attempt to execute an Inference for MATLAB document, Inference will now know the location of your MATLAB installation and will be able to proceed with document execution. 2/9/2009
After four months of fine-tuning and polishing, I'm pleased to announce that we have finally released the commercial version of Inference for MATLAB. I'd like to thank those of you who have stayed with us over the last year and provided many suggestions for to how to make Inference a better and more-useful product. That said, I want to make it clear that this is just the beginning. As a product, Inference for MATLAB will continue to evolve and improve as time goes forward. And again, I need your help to make this happen! If you have product suggestions or feedback, please don't hesitate to contact me at development@bluereference.com.
A one-year subscription to Inference for MATLAB can now be purchased from our Purchase page. Additionally, all academic users can apply for a free Academic License.
So without further ado, here's a list of what's new and what's fixed in the first commercial release of Inference for MATLAB:
What's New:
- Object Browser
- New Keyboard Shortcut Keys
- Inputs in Excel now identify datatype on creation
- New Table DataFrame input style for Excel
- Input/Output sheets created for Parts Container Excel documents
- Expression output can be placed in headers and footers in Word and Excel
- Document Execution in Inference Studio
- HTML File support (used for HTML tables)
- SharePoint document execution
- New "How-To" samples
- Streamlined QuickStart documents
- 64-bit support
- Improved DataFrame API
- Improved document execution error handling
- Improved document execution process
- Many other usability improvements
What's Fixed:
- Significant memory leak when opening code block and expression editors
- Word drop-down menu instability fixed
- Improved installation detects running instances of Office applications, and Word as Outlook email editor (Office 2003)
- Inference Online Proxy Error resolved
- Over 100 defect fixes
2/2/2009
As I write this, we are about one week away from the first commercial release of Inference for MATLAB. It's been a long time coming. The last two years of development have been a joy for me. I've thoroughly enjoyed building Inference for MATLAB from an initial proof-of-concept to a fully-featured product. Much of the thanks goes out to our loyal collaborators, who tirelessly put the product through its paces and provided many useful suggestions for how to make Inference better.
As the commercial release comes to a close, I thought this would be a great opportunity to start a more public exchange around Inference for MATLAB, and hence -- this blog. Exciting, I know. J My plan is to not just post demonstrations of features and functionality, but also to focus on illustrating how you can use Inference for MATLAB to solve real-world problems today.
Please feel free to send me to suggestions (development@bluereference.com) or leave me comments in the postings -- I want to hear your feedback!
|
|
|
|
|
|
|
|
| |
|
© 2008 Blue Reference, Inc.
All rights reserved. | 3052 NW Merchant Way, Suite 100, Bend, Oregon 97701 | 541-316-2343 |
Terms of Use
 |
|
 |
 |
 |
 |
|