# EasyLanguage Number to String

Share This Post

Table of Contents

Today we will examine the EasyLanguage number to string numtostr function.

EasyLanguage, unlike other programming languages, is very simple. This language has many preset functions that make it easier for the end-user.

You won’t have to go into complicated calculations to turn a string into a number.

Just use the function easylanguage number to string (numtostr).

The EasyLanguage number to string function is also identical to PowerLanguage, the programming language used by MultiCharts.

The codes in this article can, therefore, be adapted without problems even by MultiCharts users.

This function converts a specific number into a text string.

The function is incomplete in the language and needs only two inputs.

You will have to enter the number to be transformed or the name of the variable that contains the amount to be converted into a string.

NumToStr (3520.50, 2);

will result in “3520.50”

Let’s look at a small code to test the EasyLanguage number to string function.

Vars:
High_Yesterday(0),
Low_Yesterday(0),
Range_Yesterday(0),
Range_Yesterday_String(“”);

High_Yesterday = High[1];
Low_Yesterday = Low[1];

Range_Yesterday = High_Yesterday – Low_Yesterday;

Range_Yesterday_String = NumToStr(Range_Yesterday,2);

Plot1 (Range_Yesterday_String);

Simply this indicator calculates the yesterday range, turns it into a string using the EasyLanguage number to string function, and prints the result in the print log.

## EasyLanguage Number To String and Plot Function

Remember that you cannot, for example, plot a string variable.

Let’s take this example code:

Vars:
High_Yesterday(0),
Low_Yesterday(0),
Range_Yesterday(0),
Range_Yesterday_String(“”);

High_Yesterday = High[1];
Low_Yesterday = Low[1];

Range_Yesterday = High_Yesterday – Low_Yesterday;

Range_Yesterday_String = NumToStr(Range_Yesterday,2);

Plot1 (Range_Yesterday_String);

The plot will not be able to draw a string.

Would you like to create your simple strategy?

Would you like to perform backtests to test an approach you are using in a discretionary way?

EasyLanguage is the language for you! It is straightforward and intuitive, and you can quickly become autonomous in the programming and creation of trading systems.

You don’t need big computer science bases to start programming in EasyLanguage and PowerLanguage.

## More From Finance Strategy System

John Murphy Ten Laws

Obv Indicator

Macd Indicator

Learn more about EasyLanguage Number to String:

TradeStation Link

MultiCharts Link

ABOUT US

Financial Strategy System was   created to share what we have   learned in the last 11 years in   the market.

In this site we talk about trading,   finance, trading platform,   strategies, indicators,   automated trading systems and   programming.

You can find dozens of free   tutorials and many technical   indicators to download for free.

error: Alert: Content is protected !!