Skip to content
  • +1 (331) 256-9097
Contact Us
Ask Question in Our Discord
Download Free Trial
Quagensia
  • Quagensia Software
    • Quagensia N Edition
      • Features
      • Pricing
      • Download Free Trial
      • Request a Demo
    • Quagensia T Edition
      • Features
      • Pricing
      • Download Free Trial
      • Request a Demo
  • Pricing
    • Quagensia N Edition
    • Quagensia T Edition
  • Portal
    • Directory of Point-and-Click Strategies at Quagensia.com
    • Trading Strategy Web Directory
      • Trading Strategies – Courses & Education
      • Trading Strategies – News & Analysis
      • Trading Discussion Forum Directory
    • Trading Strategy Video Directory
    • Strategy Directory – Beyond Quagensia.com
    • Quagensia N Edition-Compatible Third-Party Indicators
    • Content Creator Support Center
  • Support
    • Quagensia Help Documentation
    • Join Us on Discord
    • Discussion Forums
    • Contact Us
  • Company
    • About Us
    • Contact Us
    • The Quagensia Blog
    • Company News
    • Logos and Assets
  • Quagensia Software
    • Quagensia N Edition
      • Features
      • Pricing
      • Download Free Trial
      • Request a Demo
    • Quagensia T Edition
      • Features
      • Pricing
      • Download Free Trial
      • Request a Demo
  • Pricing
    • Quagensia N Edition
    • Quagensia T Edition
  • Portal
    • Directory of Point-and-Click Strategies at Quagensia.com
    • Trading Strategy Web Directory
      • Trading Strategies – Courses & Education
      • Trading Strategies – News & Analysis
      • Trading Discussion Forum Directory
    • Trading Strategy Video Directory
    • Strategy Directory – Beyond Quagensia.com
    • Quagensia N Edition-Compatible Third-Party Indicators
    • Content Creator Support Center
  • Support
    • Quagensia Help Documentation
    • Join Us on Discord
    • Discussion Forums
    • Contact Us
  • Company
    • About Us
    • Contact Us
    • The Quagensia Blog
    • Company News
    • Logos and Assets
Point-and-Click Strategies and Education for NinjaTrader® and TradeStation® > Multiple Instrument Types > Multiple Instruments

Noise-Tolerant Trend Determination (Uses Tables of Data In-Memory) (Point-and-Click NinjaTrader® Strategy)

Includes point-and-click strategy for NinjaTrader® which is built into Quagensia® N Edition (for NinjaTrader®).
Noise-Tolerant Trend Determination (Uses Tables of Data In-Memory) (Point-and-Click NinjaTrader® Strategy)
Quagensia
Quagensia
Monday, May 8, 2023
Multiple Instruments
Multiple Instrument Types
N Edition
Advanced Users
Free Trial User Can Generate Code
Advanced Users
Free Trial User Can Generate Code
Noise-Tolerant Trend Determination
Some Percentage of Consecutive Bars are Similar
Strategies Built Into Quagensia N Edition
Tables of Data
Videos

Original Trading Strategy

Overview (youtube.com, Quagensia, 2:10)
Links to the section of the video titled “Using & Customizing the Built-In Strategies in Quagensia N Edition” in which this built-in strategy is covered.
Discuss on X (x.com, Quagensia)

Peer Reviews, Modifications & Responses

Contribute

Thanks for Sharing!

Trading Strategy Summary

No-code strategy building tools that lack features like tables of data, lists, arrays, and loops make it tremendously difficult or impossible to create trading strategies that can deal with the reality that prices rarely move in perfect patterns like those drawn in technical analysis textbooks.

In general, market action has a low signal-to-noise ratio, with a lot of apparently random price movements, price spikes, and countertrend movements mixed in with what to the human eye are clear market trends and price patterns that may have been bullish or bearish signals in the past and which warrant a backtest to find out.

To determine if market action similar to the noisy market trend or price pattern that you see on a chart was bullish, bearish, or non-predictive in the past, you need to create a backtestable trading strategy that enters a trade each time market action similar to the noisy market trend or price pattern occurred in the past.

That’s what this Quagensia Strategy enables you to do.

Quagensia N Edition’s features such as tables of data, lists, arrays, and loops make it possible to codelessly use point-and-click to build trading strategies that can correctly deal with the real world complexities of identifying trends and market patterns that aren’t quite perfect. These features make it relatively easy to look at market action more broadly and comprehensively with a reasonable margin of error to account for things like price spikes and countertrend movements by making it possible to create trading strategies that can do things like the following:

1. Loop over a given number of recent bars to determine if all of the recent bars were in an up trend based on one or more metrics at the times the bars closed. This provides a more complete view of whether prices are in an up trend than only looking at trend metrics of the current bar such as the slope of a moving average at the time the current bar closed.

2. Require that only a given percentage of recent bars need to be in an up trend for the entire range of recent bars to be considered to be in an up trend. This is one way to determine that the market is in a strong up trend and has been for awhile in spite of the presence of a few price spikes and countertrend price movements that would cause a few bars in the last 50 recent bars to not be in an up trend by the chosen metrics.

3. Rank the current price bar’s trend metrics against the trend metrics of recent bars to determine if the current bar is in more of an up trend than some percentage of recent bars. This makes it possible to determine if the current bar has up trend metrics that are in the 80th percentile of the last 100 recent bars.

4. Rank the current price bar’s trend metrics against only the recent bars whose trend metrics are above a certain threshold. This makes it possible to determine if the current bar has up trend metrics that are in the 80th percentile of only the bars in the last 100 recent bars who also had strong up trend metrics. This Quagensia Strategy uses this approach using tables of data.

This Quagensia Strategy is a trend following strategy that demonstrates how to do the following powerful things with tables of data:

1. Creating an in-memory table of data that is initially empty and then populating the table of data from calculations in the strategy instead of loading the table of data from a tabular data file on disk.

2. Querying and manipulating the data using 1) filtering, 2) sorting, and 3) extracting a number of rows from the bottom of a data table.

3. Doing queries whose results overwrite the data in the queried table of data.

4. Doing queries whose results are copied into a new table of data rather than overwriting the queried table of data.

NOTE #1: This strategy requires that the “Calculate” setting is set to “On Bar Close”.

NOTE #2: This strategy uses Quagensia N Edition’s Quagensia Table System, which is also called the “tables of data” feature. This feature only works properly if the proper versions of the QuagensiaNEditionRuntime.dll, QuagensiaNEditionRuntime.cs, and QuagensiaRuntime.dll files are present in the NinjaTrader® Bin-Custom folder and the QuagensiaNEditionRuntime.dll and QuagensiaRuntime.dll files are properly “referenced”, all of which is accomplished by importing the QuagensiaNEditionRuntime.zip NinjaScript® add-on file that comes with Quagensia N Edition into NinjaTrader®. If the proper versions of the QuagensiaNEditionRuntime.dll, QuagensiaNEditionRuntime.cs, and QuagensiaRuntime.dll files are not present in the NinjaTrader® Bin-Custom folder when you generate the code for a Quagensia N Edition Strategy that uses the “tables of data” feature, the Quagensia N Edition Runtime Setup Assistant will automatically open and will guide you through the quick and easy process of importing the QuagensiaNEditionRuntime.zip NinjaScript® add-on file that comes with Quagensia N Edition into NinjaTrader®.

Quagensia N Edition’s innovative Quagensia Table System makes it easy to load tables of many kinds of data, not just time series data, from tabular data files into in-memory data tables that you can query, modify, and then write back to tabular data files on disk from your strategies.

If you have valuable data in Microsoft Excel files, a database such as Microsoft SQL Server, SQLite, or MySQL, if you have access to exotic data via Bloomberg® Terminal®, Refinitiv® Eikon®, or another high end institutional platform, if you have tabular data output from MATLAB® or R, or if you have access to alternative data sources on the internet, it is generally very easy to get these kinds of data into comma-delimited, semicolon-delimited, or otherwise character-delimited tabular data files. And once you do, it is easy to get all of this data, even entire databases of data, into your NinjaTrader® strategies by simply clicking choices on the screen.

As this strategy demonstrates, you can also create in-memory data tables and populate them with data from scratch, i.e. not from tabular data files, and then create, modify, and delete rows from these in-memory data tables.

Regardless of how you create your in-memory data tables, Quagensia N Edition makes it easy to write that data to tabular data files on disk.

This allows you to run a backtest or optimization of a NinjaTrader® strategy that outputs a report containing tabular data that you can load into any database, use as input data in MATLAB® or R, or load into Microsoft Excel to manipulate further and use to create visually powerful charts and graphs that answer your questions about the markets in ways that backtest performance reports cannot.

All features just described work with data columns of 73 different types of data including: 10 numeric data types, 3 date/time data types, colors, Booleans (true or false), text, and 57 “lists of choices” data types such as the months of the year or the days of the week.

Copyright © 2023 Quagensia, Inc. All rights reserved.

How to Get the Quagensia Strategies

This point-and-click trading strategy is built into Quagensia N Edition (for NinjaTrader®).

Customize Quagensia Strategies with Your Own Ideas

Tweaking Quagensia Trading Strategies using point-and-click with the Quagensia Desktop Application is easy for non-programmers. If you get stuck you can usually find the answer you need in our online help documentation or you can ask a question in our friendly Discord community.

If you don’t want to tweak a Quagensia Trading Strategy with point-and-click to add your own proprietary trading logic, you can still download a Quagensia Trading Strategy file, open it up in the Quagensia Desktop Application, and generate its code, then backtest and optimize the trading strategy on different instruments, different bar periods (weekly bars, daily bars, hourly bars, 15-minute bars, etc.), or different bar types (time-based bars, volume-based bars, tick-based bars, etc.), and use different start and end dates.

Some tweaks you can make to the Quagensia Trading Strategies you download include:

Modify the entry & exit logic.

  • Add more conditions, remove conditions, or change them by choosing from among a very large number of components, including many exotic indicators.
  • Add or modify stop losses, trailing stops, and profit targets. Make them tighter, less tight, or based on an entirely different calculation.
  • Add or modify time stops. For example, exit after a certain number of bars either unconditionally or only if the post-entry price action did or did not exhibit certain characteristics.

Enhance the output of the strategy to go beyond simply placing orders.

  • Draw lines, shapes, and text on the chart. For instance, you can mark times or prices where each entry or exit condition of a multi-condition entry or exit was true, even if all the necessary entry or exit conditions were not true at the same time so an entry or exit did not occur.
  • Write information to NinjaTrader®’s NinjaScript® Output window or TradeStation®’s EasyLanguage® Print Log window.
  • Write information to a file. You can even output a report that can be opened in Microsoft Excel or consumed by another application that reads comma-delimited, semicolon-delimited, or otherwise character-delimited tabular data files.

Thanks for Sharing!

Watch on YouTube Watch on YouTube
Watch on YouTube Watch on YouTube

Ready to get started?

Download the Quagensia no-code strategy builder free trial and build your trading strategies now.
Download Free Trial

Under a dollar a day.

Priced to be an easy decision for most traders.
See Pricing

Join Us on Discord

Build point-&-click strategies for NinjaTrader® and TradeStation® using Quagensia®. Collaborate with other traders to get and give help, build and backtest strategies together, and grow your skills.
Join Discord

Subscribe to our Newsletter

We'll send you product updates and company news from Quagensia as well as curated lists of Quagensia-enhanced content.
Subscribe

Welcome
Content Creators

Quagensia enables content creators to make interactive content. We invite you to create Quagensia-enhanced content and share it on YouTube and other social media channels. You may submit your high-quality Quagensia-enhanced content for consideration for free inclusion on our website.
Create Quagensia-
Enhanced Content

Screenshots of the Quagensia Strategy

Here’s a screenshot of this strategy on a backtest chart in the NinjaTrader® Strategy Analyzer.
Screenshot for point-and-click trading strategy "Noise-Tolerant Trend Determination (Uses Tables of Data In-Memory)"
Here’s a screenshot of the Quagensia N Edition Strategy you can open from Quagensia N Edition and add your own proprietary logic to, then backtest on any instruments for which you have market data in NinjaTrader®.
Screenshot for point-and-click trading strategy "Noise-Tolerant Trend Determination (Uses Tables of Data In-Memory)"

Backtest and Optimize Trading Strategies in NinjaTrader® and TradeStation®

NinjaTrader® instructions: Download NinjaTrader® from the NinjaTrader® home page, then connect to their free daily Kinetick data feed and free daily and intraday Coinbase data feed, then chart the markets for free, start backtesting and optimizing Quagensia N Edition Trading Strategies for free, and trade them in live markets with NinjaTrader®.
TradeStation® instructions: Contact TradeStation® from the TradeStation® home page to obtain access to TradeStation® 9.5 and TradeStation® 10, then chart the markets, start backtesting and optimizing Quagensia T Edition Trading Strategies, and trade them in live markets with TradeStation®.

Additional Resources Relevant to This Trading Strategy

Seeking Alpha
Yahoo Finance
Benzinga
Investing.com
Google Finance
finviz
msn money
TheStreet
CNBC
Zacks
Investor’s Business Daily
ETF Database (etfdb.com)
CoinMarketCap
CoinGecko
Cointelegraph
Yahoo Finance Cryptocurrencies Screener
msn money Cryptocurrencies Screener
DailyFX
FX Empire
FXStreet
Economic Calendars (Over 30, All Free-to-Use)
Earnings Calendars (Over 20, All Free-to-Use)
Submit a link to an article, blog post, research report, or other valuable research where Quagensia is mentioned.
Use the “How to Submit Quagensia-Related Links” page linked to above to inform us about an article, blog post, or other valuable research where Quagensia is mentioned. This includes articles and research reports in both the traditional financial press as well as those on high-quality niche trading industry news & analysis websites and blogs that are in keeping with our brand. We will add links to the best articles, blog posts, and research reports both on this page and on other pages on our website, on our social media accounts, in our email newsletter, and in other relevant places.

Discussions Relevant to This Trading Strategy

WARNING: Trading discussion websites, including forums, subreddits, X, and similar discussion websites, often have a lot of profanity and offensive comments.
Discussions Beneath Seeking Alpha Articles (has a conditional paywall)
Discussions on X
Discussions on Stocktwits
Discussions on Yahoo Finance
Stocks Subreddit (r/Stocks)
StockMarket Subreddit (r/StockMarket)
investing Subreddit (r/investing)
Exchange-Traded Funds (ETFs) Subreddit (r/ETFs)
Options Subreddit (r/Options)
CryptoCurrency Subreddit (r/CryptoCurrency)
CryptoMarkets Subreddit (r/CryptoMarkets)
BitcoinMarkets Subreddit (r/BitcoinMarkets)
bitcointalk.org Bitcoin Trading Discussion
Bitcoin Subreddit (r/Bitcoin)
Forex Factory
Forex Subreddit (r/Forex)
Elite Trader Discussion Forum
Daytrading Subreddit (r/Daytrading)
See more discussion options in The Quagensia Trading Discussion Forum Directory.
Submit a link to a discussion where Quagensia is mentioned.
Use the “How to Submit Quagensia-Related Links” page linked to above to inform us about a discussion thread where Quagensia is mentioned. This includes discussions on forums, subreddits, FaceBook groups, X, and anywhere else. We will add links to the best discussion threads both on this page and on other pages on our website, on our social media accounts, in our email newsletter, and in other relevant places.

Related Trading Strategies & Education

Multiple Instruments

Main Page

Multiple Instrument Types

Main Page
Instrument List

Browse Trading Strategies & Education by Category

Account Info
Advanced NinjaScript® Strategy Events
Analyze Actual Trades
Breakouts
Button Controls on a NinjaTrader Chart
Chart Patterns
Check Box Controls on a NinjaTrader Chart
Conditional Trading Logic (If… Else If… Else Block)
Conditions
Consecutive Bars are Similar
Copy-and-Paste
Counterfactual Trading
Custom Popup Windows on a NinjaTrader Chart
Custom Quagensia Functions
Data Type Conversion and Rounding Decimal Numbers
Data Types
Draw Something
Experience Level: New, Intermediate, Advanced
File Input/Output
Gap Up/Down
Indicators
Input Parameters
Long-Short Position Reversals
Loops
Math
Media Types
Microsoft Excel
Money Management
New High/Low
News & Analysis
NinjaScript/Advanced Objects
NinjaTrader ATM Strategies
Order, Fill, and Position Info
Other Locations to Paste NinjaScript Code
Price Data
Quick Intros
Raw Code Output Actions
Raw Code Output Expressions
Reports
Session Info
Set a Variable
Sets of Conditions (With ANDs, ORs, and Parentheses)
Strategies Built Into the Quagensia Desktop Application
Strategy Info
Strategy Templates
Submit an Order
Support and Resistance
Text Box Controls on a NinjaTrader Chart
Trend Following
TriggerCustomEvent
Usable in Free Trial?
Utilities
When Advanced NinjaScript Events Occur

Browse Trading Strategies & Education by Instrument Type

Cryptocurrencies
ETFs
Forex
Futures
Multiple Instrument Types
Options
Stocks

Browse Trading Strategies & Education by Watchlist

Cryptocurrencies
FAANG Stocks
MAMAA Stocks
U.S. Equity Indices

Thanks for Sharing!

Watch on YouTube Watch on YouTube
Watch on YouTube Watch on YouTube

Ready to get started?

Download the Quagensia no-code strategy builder free trial and build your trading strategies now.
Download Free Trial

Under a dollar a day.

Priced to be an easy decision for most traders.
See Pricing

Join Us on Discord

Build point-&-click strategies for NinjaTrader® and TradeStation® using Quagensia®. Collaborate with other traders to get and give help, build and backtest strategies together, and grow your skills.
Join Discord

Subscribe to our Newsletter

We'll send you product updates and company news from Quagensia as well as curated lists of Quagensia-enhanced content.
Subscribe

Welcome
Content Creators

Quagensia enables content creators to make interactive content. We invite you to create Quagensia-enhanced content and share it on YouTube and other social media channels. You may submit your high-quality Quagensia-enhanced content for consideration for free inclusion on our website.
Create Quagensia-
Enhanced Content

Videos for New Users

Watch on YouTube Watch on YouTube
Watch on YouTube Watch on YouTube
Watch on YouTube Watch on YouTube
Watch on YouTube Watch on YouTube

Videos for Intermediate Users

Watch on YouTube Watch on YouTube
Watch on YouTube Watch on YouTube

Screenshots

For larger and additional screenshots, see large Quagensia N Edition screenshots (for NinjaTrader®) and large Quagensia T Edition screenshots (for TradeStation®).

For additional screenshots, see the list of Strategies Built into Quagensia N Edition (for NinjaTrader®) and Strategies Built into Quagensia T Edition (for TradeStation®). Select a built-in strategy that interests you and scroll down for the screenshot. Then scroll up to the top of the page and click the “Overview” link to watch the video on how to use that built-in strategy.

This is a screenshot of the point-and-click trading strategy you will build in Quagensia N Edition (for NinjaTrader®) if you follow along with the video titled Create NinjaTrader® Strategies Using Point-&-Click with Quagensia N Edition – Full Tutorial.

This is a screenshot of the point-and-click trading strategy you will build in Quagensia N Edition (for NinjaTrader®) if you follow along with the video titled "Introduction to Quagensia N Edition".

Click the gear icon that appears when you place your mouse pointer over the location to which you would like to add trading logic. A context menu will appear with filtered options to choose from.

Click the gear icon that appears when you place your mouse pointer over the location to which you would like to add trading logic. A context menu will appear with filtered options to choose from.

Quagensia N Edition

  • Features
  • Pricing
  • Download Free Trial

Quagensia T Edition

  • Features
  • Pricing
  • Download Free Trial

Trading Strategy Portal

  • Directory of Strategies at Quagensia.com
  • Trading Strategy Web Directory
  • Trading Strategies – Courses & Education
  • Trading Strategies – News & Analysis
  • Trading Strategy Video Directory
  • Strategy Directory – Beyond Quagensia.com
  • Trading Discussion Forum Directory
  • Content Creator Support Center

Support

  • Quagensia Help Documentation
  • Discussion Forums
  • Contact Us

Company

  • About Us
  • Contact Us
  • The Quagensia Blog
  • Company News
  • Logos and Assets
  • Terms of Service
  • Privacy Policy
  • Cookie Policy
  • DMCA Policy
  • Forums Code of Conduct
  • Quagensia Desktop Application EULA
  • Site Map

Follow Us

Youtube X-twitter Facebook-f Linkedin

Thanks for Sharing!

Join Us on Discord
Subscribe to our Newsletter

DISCLAIMER REGARDING THE RISKS OF TRADING AND INVESTING

Trading and investing in the financial markets can involve a high degree of risk of financial losses, including losing all of your initial investment or even more than your initial investment. For this reason, you should not invest or trade with money that you cannot afford to lose. The use of leverage can work for you or against you and is highly unsuitable for many investors. The trading of futures, forex, contracts for difference (CFDs), options, and cryptocurrencies is highly unsuitable for many investors. Neither trading nor investing is suitable for all people. Most traders lose money. Before deciding to trade or invest in the financial markets you should carefully consider your financial objectives, level of experience, and risk appetite. Past performance, whether actual or hypothetical, is not necessarily indicative of future results. You must be aware of the many risks associated with trading and investing and be willing to accept them in order to trade or invest in the financial markets. You should seek advice from a qualified independent financial advisor if you have any questions, doubts, or points of confusion regarding these many risks.

DISCLAIMER REGARDING HYPOTHETICAL PERFORMANCE RESULTS

Hypothetical performance results have many inherent limitations, some of which are described below. No representation is being made that any account will or is likely to achieve profits or losses similar to those shown. In fact, there are frequently sharp differences between hypothetical performance results and the actual results subsequently achieved by any particular trading program.

One of the limitations of hypothetical performance results is that they are generally prepared with the benefit of hindsight. In addition, hypothetical trading does not involve financial risk, and no hypothetical trading record can completely account for the impact of financial risk in actual trading. For example, the ability to withstand losses or to adhere to a particular trading program in spite of trading losses are material points which can also adversely affect actual trading results. There are numerous other factors related to the markets in general or to the implementation of any specific trading program which cannot be fully accounted for in the preparation of hypothetical performance results, all of which can adversely affect actual trading results.

DISCLAIMER REGARDING TESTIMONIALS

Testimonials appearing on this website may not be representative of other clients or customers and are not a guarantee of future performance or success.

IMPORTANT LEGAL INFORMATION REGARDING TRADEMARKS AND COPYRIGHTS

Quagensia® N Edition and Quagensia® T Edition are products of Quagensia, Inc., a company which has no affiliation with either NinjaTrader, LLC or TradeStation Technologies, Inc. Neither NinjaTrader, LLC, nor TradeStation Technologies, Inc., nor have any of their respective affiliates endorsed, recommended, or approved Quagensia® N Edition or Quagensia® T Edition. NinjaTrader® and NinjaScript® are registered trademarks of NinjaTrader, LLC. TradeStation®, EasyLanguage®, and Portfolio Maestro® are registered trademarks of TradeStation Technologies, Inc. Bloomberg® and Bloomberg Terminal® are registered trademarks of Bloomberg Finance L.P. Refinitiv® and Refinitiv Eikon® are registered trademarks of Refinitiv or its affiliates. MATLAB® is a registered trademark of The MathWorks, Inc.

All trademarks and copyrights are the property of their respective owners.

Copyright © 2023-2026 Quagensia, Inc. All rights reserved. Quagensia® is a trademark or registered trademark of Quagensia, Inc in the United States, the European Union, China, Japan, and other countries.