Creating Stock List
Author: 07nioe
Creation Date: 9/10/2014 11:38 AM
profile picture

07nioe

#1
Hi all,

Is it possible to create a list with the Top20 performing Stocks in the s&p500. Or make list of the stocks simply sorted by performance?

Thanx for help
Niels
profile picture

Eugene

#2
Hi Niels,

There are numerous ways to skin this cat, especially elegant if using LINQ (unfortunately, adding LINQ in versions below 6.7 would require some manipulation with assembly references). For example, here's one out of the possible ways:

CODE:
Please log in to see this code.
profile picture

07nioe

#3
Okay. Thank you. But, if i run the script, I cannot see a list. Where do I find it?

Best
Niels
profile picture

Eugene

#4
In the Debug window when running the script in single symbol mode.
profile picture

07nioe

#5
Ah, okay. Found. Thank you. And if WL could export the list into a file for further use and Analysis, it would be perfect.

Thanks again

Best
Niels
profile picture

Eugene

#6
It's .NET where anything is possible. Please see Exporting to ASCII comma-separated files (CSV).