CS2005
error name takes expected arguments, not got.
#What it means
The function was called with the wrong number of arguments. The message says how many it takes and how many it got.
#Typical cause
- A required argument is missing, such as the length of
ta.sma. - Too many arguments were given.
#How to fix it
Check the function's signature in the reference (or hover its name in the editor) and pass every required argument.
#Example
//@chartscript 1
indicator("SMA", { overlay: true })
plot(ta.sma(close))Fixed
//@chartscript 1
indicator("SMA", { overlay: true })
plot(ta.sma(close, 14))