Announcement

Collapse

Announcement

~ gang gang ~
See more
See less

Okay I'm In

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    i mean honestly, a swing trade is nothing but a long scalp. there is so much DNA shared between them. the live market data -> python path is tricky only because there are, to my knowledge, no public resources for real time data. so you have to work through an API.

    and the only API ive had any success with was on ally.com. and that rapidly spun beyond my technical means because the authentication layer is really something of a bag of wet dicks. i found some interesting code snippets for it on github but just never quite got my groove on beyond some very basic utilities (checking current stock price etc).

    there have been a lot of great high level threads on fintwit about best in slot DBs for accruing/analyzing level 2 data, T&S, so on. btw you could write an extremely profitable bot based on nothing but Time and Sales (T&S) but i spent a good week looking for people who would sell me a T&S feed and got nothing to show for it.

    but... perhaps one could hook into the thinkorswim T&S feed.......? worth consideration. i wish their linux client was open source....

    Comment


    • #17
      I looked up T&S, and it appears to be synonymous with order books? Looks very similar to what I've seen on crypto exchanges.

      As far as basic real-time market data goes, looks like this is not going to be a problem. Lots of APIs (such as the Google Finance API) and libraries out there, so I don't have to try any hacky shit like scraping ToS or whatever. Even before I have anything close to a firm grasp on trading, I can go nuts playing around with this data in Python.

      I'm still doing reading up on the fundamentals of trading, so I haven't yet given a single thought to strategy, but I learned today that I'm going to have to pay $6 commission per trade for OTC stocks. I assume this will be most trades? If so that could be a real bitch. If I buy $100 of something and net a 12% gain, the commission eats HALF of it. Adding in the fact that you still get raked on losing trades, and that's just going to obliterate my winrate. I guess we have to be super aggro with the bankroll to mitigate this?

      Comment


      • #18
        oh its just one way to skin the cat. its generally considered the one stand-alone indicator capable of being used to enter/exit positions with real accuracy. it takes a lot of training/instict/knowledge to really use right, none of which i have btw, but if i was looking to leverage ML against one singular stream / source of truth, without question it would be T&S, because you can essentially extrapolate so much from it.

        Comment


        • #19
          GRANDPA SONATINE IS THIS TRUE???

          Click image for larger version

Name:	WSBfaq.png
Views:	132
Size:	44.8 KB
ID:	1119

          Comment


          • #20
            nothing is true, everything is permitted

            Comment


            • #21
              if you want to learn more about options, and i highly suggest you take the plunge, this thread is kinda fucking great:

              https://www.reddit.com/r/wallstreetb..._tips_from_my/

              Comment


              • #22
                Alright, I have been learning from Ziptrader (and a few other resources) about using indicators like SMA (of varying time periods), RSI and MACD to identify entry and exit points in swing trades.

                Normally at this point I would dip my toes in the waters and begin paper trading. Manually searching for stocks that appear oversold on the RSI chart, with a history of bouncing between oversold/overbought on a regular basis. I'd probably make some mistakes doing this and perhaps slowly learn from them. Maybe I will go ahead and do a bit of this.

                But I have a more interesting idea. I'm going to take some historical market data (perhaps all of the S&P from the last 5 years or so). I'll load this into Python and write some code for tracking the SMA (short and long-term), RSI and MACD of these stocks. This will have the additional benefit of helping me better understand these metrics since I'll have to carefully check the formulas and make sure the output matches ThinkOrSwim.

                Then I'll have my script parse through all of the data and search for entry/exit points based on these metrics. At first I will manually give it some parameters. Maybe it only looks for oversold stocks that hit 30 and 70 RSI at least 5 times each per week (or something like that). Then I can simulate 4 years of trading with this strategy and see how it goes.

                Once that is working, I can then run through tons of simulations (of 4 years each) with a range of strategies. The parameters can be different RSI thresholds, or perhaps MACD crossovers. Maybe some rules for exiting positions that are going badly. At some point I should use a neural network to tune this, but for now I will brute force it with some randomized settings.

                It shouldn't be too resource intensive to run a few thousand simulations with random strats. I'll take the 100-best performing simulations and run their strat against the 5th year of market data, to see if they might be legit or just overfit. If any of them look profitable, I can test these strategies in the current market.

                I still barely understand what these indicators mean, and would like to spend more time learning about them. But for now I can at least get started on playing with sims, and perhaps gain insight from that as well.

                Comment


                • #23
                  that... sounds.. incredible.

                  tbh i dont understand a lot of the real granular behind the scenes physics of most indicators. like i can guess the geometry but the particulars are beyond me and frankly to some extent beyond my interest. i get the feeling there is a lot of algebra lurking back there.

                  Comment


                  • #24

                    "100 backtests will take a lot of time"


                    Click image for larger version

Name:	image_143.jpg
Views:	373
Size:	115.4 KB
ID:	1263
                    Last edited by SrslySirius; 07-03-2020, 02:46 PM.

                    Comment


                    • #25
                      also our band is 100% called 'the backtest boys' i want that to be perfectly clear.

                      Comment


                      • #26
                        I've run into a snag with data. Unfortunately it seems that the Google Finance API is no longer supported. In fact, Google Finance no longer exists. How very Google of them.

                        Yahoo Finance has a nifty python library, but for 1-minute intervals it only offers 7 days of data. Useless.

                        Kibot offers a lot of data packages, at intervals down to the tick. It also has bid/ask history, which I believe you were inquiring about Sonatine. But Kibot gets very very pricey.

                        I'll keep looking for alternatives. I can settle for 30-minute intervals if need be. That should be fine for swing trading, right?

                        Comment


                        • #27
                          you can extract up to 30 days of 1 minute ticks from thinkorswim if memory serves... regarding intervals, i think the best answer i can give is that various stocks behave (ha ha) in fairly specific ways. so a 30m interval might be great for some securities but totally inadequate for more volatile ones. like 30m would be absolutely useless in TSLA i imagine. plus event driven market etc etc.

                          but honestly the best way to answer that would be to model then backtest, of course.

                          Comment


                          • #28
                            I'm suffering some analysis paralysis lately. I've reviewed a bunch of choices for datasets. There are some okay-ish free options, but it's a choice between years of history at day-increments, or like 30 days of 1-minute ticks.

                            In the realm of paid options, there are some robust packages, but I'm honestly kind of balking at price. Loss aversion is weird. I'm not concerned at all about blowing up my $1k Ameritrade account, and half-expect to do exactly that eventually. But plunking down $400 for a csv file feels a bridge too far.

                            Decisions, decisions.

                            Comment


                            • #29
                              so give me some context when you get a mo. like are you looking for historical data for an alg driven decision engine or is this part of you wanting to get feet wet in the market in general? i greatly admire the hutzpah if youre just skipping the whole analysis phase and diving straight into algville btw.

                              Comment


                              • #30
                                If you'll forgive the poker analogy, I have learned the basic rules of the game and I know what hands beat what. I have read a few things about tactics like check-raising, concepts like ICM, vague ideas on how to put people on ranges. But I haven't played a single hand. So even with this surface-level knowledge of intermediate-to-advanced concepts I am a massive fish.

                                So I'm going to build myself a PIO-solver to teach me how to build a strategy, instead of doing years of trial-and-error like everyone else.

                                Comment

                                Working...
                                X