1

I'm trying to plot horizontal line on daily 20 ema price, but getting error while doing so ' Error An argument of 'series float' type was used but 'input float' is expected' I'm a beginner, any help is appreciated.. How to plot the same on multiple timeframes like weekly, monthly

Here is the code..

//@version=5
indicator("My script", overlay=true )
e20 = ta.ema(close, 20)
hline(e20, title = "DEMA", color = color.green, linestyle = hline.style_dotted, linewidth=2)
plot(close)
Raj L
  • 11
  • 1

1 Answers1

0

Value of daily ema changes on each bar. If we draw a line from each daily ema points to another, it would not be horizontal a line. A horizontal line must have a constant value, not a moving one.

What I mean is

erdem
  • 11
  • 4
  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Dec 02 '22 at 07:33