Why are DLLs better than Spreadsheets?

Forgiving Computers began developing trading systems using spreadsheets for Sierra Chart. If you are familiar with Excel or other spreadsheet applications, you know spreadsheets provide a quick way to do number crunching with immediate results. The Sierra Spreadsheet functionality integrates the ease of use of spreadsheets with the ability to combine price action data, with study results (Moving Averages, Bollinger Bands, etc.) and create signals or new studies based on the data of the current and previous candles.

A Dynamic-Link Library, or DLL, is an Application Extension that adds functionality to Windows applications in a modular way. Studies provided by Sierra Chart are written in C++ and compiled into DLLs. Customs studies and systems can be added to your charts the same way. DLLs can be shared across charts and chartbooks with none of the drawbacks of sharing spreadsheets across chartbooks.

There are several advantages to this approach.

  1. Speed
  2. Memory
  3. Independence
  4. Complexity

Speed

Because DLLs are compiled, they use the processor’s native instruction set to perform calculations. Spreadsheets add layers of overhead. Whether it is a Spreadsheet Study, System with Alerts, or Trading System, the data has to get into the spreadsheet in the proper format, be processed with the specific formulas needed to determine the results, and then translated back into the study that incorporates the results into your charts. Also, the spreadsheet has to wait for all the studies to complete their processing before beginning to evaluate results. All that takes time, even though the spreadsheet study itself is compiled, the formulas that make up the spreadsheets are converted from Excel format to an internal format.  This can result in trades being taken fractions of a second later than with DLLs.

If you use the same spreadsheet in multiple chartbooks, using the same chart number, Sierra will update the “sheet” for the first chartbook, then moments later, update the next, and so on. This is inefficient and can cause more delays. (This is why you need to take extra steps to “clone” a chartbook with spreadsheets.)

Memory

DLLs take up less space in memory and on your disk. One copy of the DLL is sufficient for all the charts it is attached to, where you need multiple copies of spreadsheets to avoid the above update cycle. Less memory usage also improves performance.

Independence

A compiled C++ DLL study is “linked” into the main Sierra application, in as many places as you like. No “cloning” is needed to maintain top performance, as is necessary with spreadsheets.

Complexity

More functionality is available to the custom study with DLLs. For example, BID/ASK data, and Volume Profile data can be incorporated into a custom study with DLLs, but not with spreadsheets.

Other advantages include automatic installation and updating, user-based licensing, copy protection, and time-limited trial versions.

There are some disadvantages to using DLLs. Spreadsheets can be used to quickly develop studies to try out ideas and see results quickly. C++ requires some programming skills, where spreadsheets require some Excel skills. As with anything worth learning, expertise comes with time.

Conclusion

C++ based custom studies provide the best methods for adding functionality to Sierra Chart. They can be used for new studies, creating alerts, and for complete auto-trading solutions.  Forgiving Computers is in the business of providing trading solutions. We will develop most new studies in C++, however, we will also do custom spreadsheet solutions for customers that want them. Either way, we want you the trader to be successful with the custom decision support tools we provide.