lee-I-O=coke-A
Member
I am trying change script to symbol in ( example 2 ) in lieu of SPX in ( example 1 ).
Can someone kindly help me with this endeavor. thanks
def stk = round(((close / close[126])-1)*100,2);
def bmark = round(((close("SPX") / close("SPX")[126])-1)*100,2);
def c = stk-bmark;
plot data = stk;
data.AssignValueColor(color.BLACK);
AssignBackgroundColor (if c > 0 then color.GREEN else if C < 0 then color.Red else color.gray);
----------------------------------------------------------------------------------------------------
def symbol = getsymbol;
def stk = round(((close / close[126])-1)*100,2);
def bmark = round(((close(symbol) / close(symbol)[126])-1)*100,2);
def c = stk-bmark;
plot data = stk;
data.AssignValueColor(color.BLACK);
AssignBackgroundColor (if c > 0 then color.GREEN else if C < 0 then color.Red else color.gray);
Can someone kindly help me with this endeavor. thanks
def stk = round(((close / close[126])-1)*100,2);
def bmark = round(((close("SPX") / close("SPX")[126])-1)*100,2);
def c = stk-bmark;
plot data = stk;
data.AssignValueColor(color.BLACK);
AssignBackgroundColor (if c > 0 then color.GREEN else if C < 0 then color.Red else color.gray);
----------------------------------------------------------------------------------------------------
def symbol = getsymbol;
def stk = round(((close / close[126])-1)*100,2);
def bmark = round(((close(symbol) / close(symbol)[126])-1)*100,2);
def c = stk-bmark;
plot data = stk;
data.AssignValueColor(color.BLACK);
AssignBackgroundColor (if c > 0 then color.GREEN else if C < 0 then color.Red else color.gray);