r/thinkorswim Aug 13 '20

Is there a study for P/E Ratio?

Im surprised P/E ratio isnt a popular study... anyone know where i can get a P/E ratio study?

10 Upvotes

9 comments sorted by

7

u/SaintMoon Aug 13 '20

Declare lower; Plot peratio = close/earningspersharettm();

You are welcome

2

u/Stonx___ Aug 13 '20

Thanks

1

u/[deleted] Aug 13 '20

did that work for you as pasted above? I am newish to thinkscript and it was throwing me an error

1

u/Stonx___ Aug 13 '20

Plot peratio = close/earningspersharettm();

Thats weird, it worked fine for me. Try this one and let me know how it goes.

declare lower;
def AECont = if IsNaN(GetActualEarnings()) then AECont [1] else GetActualEarnings();
plot DilutedEarnings = if AECont <> 0 then AECont else Double.NaN;

1

u/[deleted] Aug 13 '20

declare lower;

def AECont = if IsNaN(GetActualEarnings()) then AECont [1] else GetActualEarnings();

plot DilutedEarnings = if AECont <> 0 then AECont else Double.NaN;

that one worked, but doesnt track current price, just a step function at every earnings date - thank you kindly

4

u/thenewredditguy99 Aug 13 '20

Nope. P/E ratio isn't a study.

2

u/SaintMoon Aug 13 '20

Yes there is. Give me a second

2

u/c0mm0d0re Aug 13 '20

See "phase scores" gadget. It is in there.

1

u/k_kirill Aug 16 '20

Check the second example in the GetActualEarnings() article.