Example Code

Character Frequency VI

Code and Documents

Attachment

Overview

This VI is used to calcualte the frequency of characters (Strings, Numerics, Symbols) in a document

 


Description
Calcualte the frequency of characters (Strings, Numerics, Symbols) in a document, and return a look up table each individual character found along with the frequency at which they occur.

It could then use this to compress data (especially over RS-232) by using a binary table instead of sending 8-bits (1-byte) per ASCII character regardless of frequency, and converting this to a static LUT on an embedded device.

 


Requirements

  • LabVIEW 2012 (or compatible)


Steps to Implement or Execute Code

  • Download the attachment to your computer
  • Open the VI "Frequency Binary Table 2012 NIVerified.vi"
  • Run the VI

 

Additional Information or References
VI Snippet

 VI Snippet.png

 

 **This document has been updated to meet the current required format for the NI Code Exchange.**

 

Applications Engineer

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.