Jump to content

Michael P

Members+
  • Content Count

    18
  • Joined

  • Last visited

Everything posted by Michael P

  1. @Alastair I looked at EdgeWonk for the first time last night It seems to have a wide range of features. It seems to have a focus on long term views. I am not knowledgeable enough to make a general assessment and it would not be helpful for me to make a general comparison between the two. I noticed a couple of features in EdgeWonk I am interested in implementing. Sturctjour is focused day-trading and trading strategy. I am interested in features that help to identify, study and hone those skills. EdgeWonk had a couple of multi-day views that looked promising in that regard to me. TraderVue's reports include many chart types that will also be included in structjour.
  2. @ecadaret, Thanks for that suggestion. I had not looked at EdgeWonk before. Its breadth is dizzying. The soon upcoming statistics module will have similarities with TraderVue reports. The plan has always included a selection of charts that can be modified by selected date ranges and filtered by strategies and tags. TradeVue does that nicely with a fairly clean interface. I will release to PyPi a new version when the first set of charts are included in the statistics module.
  3. @ecadaret Glad to hear it. I have been putting a lot of work on it and the version on github has a lot of changes and you can check out the code.. https://github.com/MikePia/structjour.
  4. New version of structjour Version 0.9.92-Alpha.001 (09.92a1). New version is uploaded to PyPi pip install --update structjour Pilot Fish, changes include most of the things we discussed. Thanks * Added A Risk:Reward cell to show Actual P/L:Amount Risked * Added a DB migration procedure and added migration for the new RR * Automatically save to DB when user changes the date * Automatically load the trades from DB when user changes the date and has selected DB * Added a back up and restore procedure available in the menu. Backup the db and settings * Added an initialize to the backup. Meant for testing, but available for user. * Created code to handle stock API limit reached. * Created an automatic rollover for stock API. When one fails, try the next till one succeeds or all fail. * Added rules to the APIChooser to implement the automatic rollover. * Got rid of a button so now there is one button for db, one for DAS and one for IB statement * Set initialize defaults for logfile and db files. * Removed user choice of outdir and made it default only. * On first run, or runs that have lost the settings, pop up the file settings dialog before opening the program * Automated the create dirs procedure and removed it from file settings. User can override the auto gen in a seperate menu entry. Regarding the automatic loading of trades. Its implemented to load the trades in the DB when database is checked and the date changes. This makes it difficult to enter a specific date or to quickly scroll as every change tries to load the trades of the day. I am adding a popup calendar widget to help. Alternatively, it could load trades when the user presses enter instead of automatically loading but I think that kind of defeats the purpose. Regarding automatic loading of charts. I did not implement it because each chart is currently a seperate HTTPS call and for some APIs, it would eat through their quota of free calls and could take a long time. I plan to implement a caching of chart data for each day. That will lessen the demands on the REST HTTPS calls and then automatic chart loading will make more sense. It should mean that only one call per ticker for each day is required. It will also allow the charts that use this data to be interactive and respond to mouse location with price, time or volume info. I have started working on a statistics module. Next update should include the beginnings of that. As always design ideas, suggestions, comments , bug reports and even forking from github are all welcome. Nothing is set in stone. I think of this as BBT software because it represents the point of view I have gained as part of this community.
  5. Ok then... The folders will be named and created without interaction. If they don't exist structjour will create the directories for the current and the upcoming month based on the system date. In case the system date is messed up, I will provide a separate menu entry to disable automatic creation and choose for which months to create directories. Likewise the sqlite database files and the logfile will be automatically named without input. Those are the easy ones. I think you are right that the statistics tracking stuff should include some user created categories. Some basic entries for everyone will include strategy, win/loss, risk/reward and time of day. Maybe after that its a blank slate. Allow the user to create keys with multiple possible values. Emotional state, for example, could be a key. But how to make this seamless to use? All my first implementation ideas are clunky. Also the ux to view statistics needs to be completely simple and intuitive and I have not come up with it. The database works more like you describe than is apparent. After reading a file, all access to the information goes through the database except that files can be re-read. This makes sense for DAS imports as the user may have additional trades. It does not make sense for IB statements as the files always include entire days. The interface is again the problem. It seems to provide more choices than are necessary or helpful. Its evolved to this point, but it needs to simplify further. Structjour can read in a yearly IB statement and all those trades are stored. When 'load' is pressed, the trades from a single day are loaded to be viewed and reviewed. But after all that, I think what you would like to see is automatically loading up the days' trades(?) I agree that should happen. It should probably happen when the user changes the date. Right now, changing the date just shows what is available and requires the user to read a file or load the data. If DAS is selected, changing the date shows whether a import file exists for the selected day. If database is selected, it shows how many trades are in the database for the day. The interface has to solve both locating possible files to read and loading already stored data. With very little change, I can see how to implement automatically loading the days trades when the database checkbox is checked. But I would really like to see a more intuitive and simplified interface that doesn't have all the check boxes and buttons. Finally support for other databases is planned by abstracting the database interface to django models. All databases supported by django will then be supported. Thanks for your feedback People with design ideas, please feel encouraged to contribute.
  6. This is good stuff. Thank you for taking the time. I am continuously interested in ideas and bug reports. You can continue to post here or open issues on github. Regarding the folder structure. Is there real value to allowing the user to edit the folder names? Your alternative of providing the feature as an advanced setting is better than the current but what about just removing the choice. What would be lost? The simplicity gained might be worth it. Could ask the same question for choosing the logfile name and database names. As the program evolved It seemed like I personally needed these choices but now maybe all three are just bad ux design. On tracking statistics. I had always planned on creating a long term statistics module of some kind. The minimal bit that is done is exporting trades to a an excel file called disciplined.xlsx. It tracks winning, losing and break even trades by month. The export was meant to be temporary until I create something better. This new statistics tracker page, I think, should give weekly, monthly and yearly statistics based on strategy, R:R, time of day, and success (red vs green). Your idea goes beyond what I had planned. Tracking FOMO, greed, DAS key errors seems useful. Its the etc part that needs work. Should there be a complete list of human traits that affect a trade? This list would allow the user to add items to it (amount of sleep, attitude ...). Or would it be better focus to limit it to universal things like greed, fear, and FOMO? Too many factors could make the analysis less meaningful. Next is how to view the statistics and the interface to filter what statistics to view. I am going to put this one aside for a little while. I need a better idea of what to create. If anyone has thoughts and design ideas, I would love to hear them. An aside, structjour could support importing trades and user data into other excel programs that already implement long term statistics. Or maybe an excel expert could update disciplined.xlsx to show more statistics. The imported trade data includes strategy but disciplined.xlsx does not use strategy in its statistics. I debated automatic chart loading and went back and forth. I am going to go ahead and put it in as an option and see how it works. The two main issues are the differing limits of each free data API (Barchart, Alphavantage, World Trade Data, and Finnhub) and the default chart interval, begin and end points. Actual RR value based on (original) stop loss and profit-- could be done.
  7. Hello PilotFish, The program does create the necessary folder structure but it requires you to initiate it. Look at the dialog png a couple posts up. On the right side of the dialog see the bit where it says "Create journal file directories for the month of ...." Choose the month and year and click the "Create Dirs" button. The green directory indicates the directory exists for the chosen date. Suggestions on how I can simplify this procedure? Maybe it should be completely automatic triggered by the system date and opening the dialog or something. Each DAS import file must be uploaded. DAS resets the trades positions window every day. Its not possible to have a multi-day import from DAS. I don't know how to access DAS programmatically. Its probably possible but would require me to purchase a subscription to the DAS API. But the import should be relatively seamless. Incidentally you can import ib statements of any length, monthly, yearly, whatever. This is part of the main window. With DAS import checked, use the date widget to locate the files exported from DAS. Files that exist will be in green. If no trades.csv exists for a particular date, it will show red. Click on Read File to import into structjour. (The date widget lets you tab from month to year to day. Using the arrow keys on your keyboard will increment. ) Then click Database and Save. This UI evolved from my usage. While it seems intuitive to me, I may be the only one. I would like to make this pre-alpha software completely seamless and bullet proof. Anything is possible for the interface if you have any suggestions. Your shared experience is very valuable. Thank you.
  8. The dialog does not fire up? I placed a new version on pypi pip uninstall structjour pip install structjour should be version 0.9.91a23
  9. Thank you, that was very helpful and will be able to prevent it in future versions. The problem seems to be there is no database file listed. While that should not have crashed the program (future will have a dialog box with instructions), it has left structjour in a state. I can reproduce the error by removing the databases in my filesetting dialog. It can be fixed by running the the file-settings dialog as its own program and setting file names for the database files. The following command should work on your system: python C:\Users\AppData\Local\Programs\Python\Python36-32\lib\site-packages\structjour\view\filesetcontrol.py Unless you have multiple versions of python on your system. You could be more specific with something like: C:\Users\AppData\Local\Programs\Python\Python36-32\python.exe C:\Users\AppData\Local\Programs\Python\Python36-32\lib\site-packages\structjour\view\filesetcontrol.py Choose file names for the two database files in the top right of this dialog. Any name is fine and they can be the same file. Then open structjour again. Should work.
  10. You need to export the Trades window from DAS. There is a bit of setup required. In Structjour, open file->file settings. At the top left choose a journal location. Click the next four buttons to get default settings. On the top right, choose a database name (any name is fine and the two database files can be the same file) Finally click the Create journal directories for the current month. Now from DAS export your trades window to your journal directory. If you used default settings, name the file trades.csv. From Structjour import it by selecting DAS import radio button and the 'Read File' I will be glad to help with what ever else you need. If you are running this from the command line and it crashes, I would appreciate the stack trace it prints.
  11. Not at all. It is open source and 100% python.
  12. That's great. But wait for an update to download. (or re-download) There is an initialization problem. Should be ok in a couple hours. I'll post here when its ready
  13. Hello BearBull Traders. I have created some journaling software that I have found useful. I call the program Structjour, as in a Structured Daily Trade Review Tool. It is meant for Day Traders in Stock Equities (who use DAS and/or IB). I have been working and using this program for about a year. Its sill a pre-release (version 0.9.9-Alpha). The design has been inspired by members of BBT (Thanks Pete, William, Robert and too many others to list). Anything I got wrong is all mine. I am seeking feed back in bug-reports, requests, suggestions and assistance in any form that you believe will help make this more useful. It has only ever run on my system and I am expecting un-planned-for bugs and oversights. Its alpha software and the installation is a bit geeky. If you don't mind that, I would appreciate your feed back for bugs, user interface suggestions, features and whatever. The features of the program include: Import from DAS Trader Pro or Interactive Broker Statements. If requested I plan to include other brokers' statements. Tickets are divided into trades and displayed showing entries, exits, PnL, and the diff between initial entry and exit and some other stuff. A place to enter your initial target and stoploss can detect when the stop is violated and figures the lost PnL. The loss amount can be edited to reflect loss of real or potential PnL due to breaking your rules. For your trade review, there is a strategey dropdown to choose from, a location to describe entrances/exits, a location to analyze, and a location to summarize which will be included in your daily summary. The strategy dropdown box on the main page can add new strategies to your list. Strategies are supported by the strategy browser where you can define your strategies and check whether to include them in the dropdown box on the front page. In the Strategy browser, you can define your strategy and provide a couple images for each strategy. Additionally you can add and view web pages that relate each strategy. I have an idea that some people may want to provide a 'strategy package', a group of defined strategies that can be uploaded into the Structjour database. Charts can be 1) automatically generated 2) copied from the clipboard or 3) loaded from a file. Data for automatic chart generation has three possible sources. Alphavantage and Barchart (free APIs) and Interactive Brokers python API using IB Gateway or Trader Work Station. If you have all three APIS setup, structjour will choose one based on availability and your set preference. The setup for Alphavantage and Barchart requires you get an API key (very simple and available to everyone). The ibapi data (setup more complicated) has the advantage of providing after hours data and long historical availability. Automatic chart generation can include Moving averages and VWAP. All charts are stored in a directory for that day providing easy access. Input files are limited to DAS Trader PRO exports and IB statements (Activity, Trade and Flex statements). At some point in the future, other brokers' statement formats may be added (depending on interest) Review suport includes setting your original target and stop loss. Exceeding your stop loss will trigger an amount lost to be shown. The Amount lost can be edited used to display and explain missing potential income from not following yhour rules. Each trade has a notes and analysis section. Navigation between days is done with a date widget. Just Change the date and click read or load to read a new file or load saved data. The daily summary has a place to store notes that refer to the whole day. A summary of Wins and losses is displayed that includes the summary made for each trade. Everything is stored in a light-weight sqlite database The entire day can be exported to an excel file which includes the easy to read forms for each trade and the charts. All of your trades can be exported to an excel file (a tweak of 'DisciplinedTrader.xlsx) which shows monthly and yearly statistics This software is free and I plan for it to remain free for BBT. Installation instructions: From any shell that runs python 3.6 or greater type pip install structjour The program will be installed in your python scripts directory. Click on it, create a shortcut or run it from the command line. Features of the program Import from DAS Trader Pro or Interactive Broker Statements. Tickets are divided into trades and displayed showing entries, exits, PnL, the diff between inital entry and exit and some other stuff A place to enter your initial target and stop loss can detect when the stop is violated and figures the lost PnL. The loss amount can be edited to reflect real or potential PnL loss. There is a strategy dropdown box to choose from, a location to describe your trade, a location to analyze your trade, and a location to summarize your trade. The summary will be included in a daily summary. The strategy dropdown box on the main page can add new strategies to your list. Strategies are supported by the strategy browser where you can define you playbook and determine which strategies should be included in the front page dropdown box. In the strategy browwer youo can describe your strategy in detail, provide a couple images. Additionally you can add web and view pages that describe your strategy. Charts can be 1) automatically generated that include entries, exits and moving averages, 2) Copied from the clipboard, or 3)Loaded from a file. The data for the automatic chart generation has three possible sources, Alphavantage and Barchart (free APIs) and Interactive Brokers python API using IB Gateway or Trader Work Station. If you have all three APIs setup, structjour will choose one based on availability, time of day and preference. The setup for Alphavantage and Barchart requires an APIKEY (very simple and available to everyone) The IB data requires an Interactive Brokers account to be effective. Navigation between days is done by entering the date in the date widget. The daily summary provides a place to store notes that refer to the entire day. It also gives a summary of wins, losses, average win/loss, max win and loss and provides a traditional table based view of the day's trades All the data is stored in a local sqlite database which is represented as a file in your machine. Export the entire day to Excel. They are shown with a similar form as structjour including all your charts and analysis Export all your trades to Excel to show longer term, monthly and yearly statistics.
  14. I put the script in exactly as above. No Buy, Price, or Route tokens. The excel thing is kind of a shame as the range variables in Sheets are more elegant, but referring to each cell instead works in both Sheets and Excel. I recommend a small edit. Add a variable settings.send_load = {Send, Load} to the settings sheet and refer to it in the Hot Keys sheet V3. For the stop loss, it seems it ought to be possible to get StopPrice from something like StopPrice= Price-100/Share where 100 is the amount risked set in your Sheets app. I can't get it to work. Maybe you can. It doesn't seem to be willing or able to set a float (StopPrice) using an int (Share). Here is the script i was trying. The first part is entirely from your configuration. And I added : Share=Pos;ROUTE=STOP;StopType=Market;StopPrice=Price-75/Share;TIF=DAY+;SELL=SEND to get: DefShare=BP*0.5; StopPrice=Price; Price = Ask - Price + 0.01;SShare = 75 / Price;Share = DefShare - SShare; DefShare = DefShare + SShare; SShare = Share; SShare = DefShare - SShare; Share = 0.5 * SShare; TogSShare; ROUTE =SMRTL; Price = Ask + 0.05; TIF=DAY+; BUY=Send; DefShare = 500;Share=Pos;ROUTE=STOP;StopType=Market;StopPrice=Price-75/Share;TIF=DAY+;SELL=SEND Note that it does create both orders if I use StopPrice = Price - .15 But of course, .15 is just arbitrary.
  15. Possible problem. I don't think the SShare variable works as an unsigned int. This script SShare=256; Share = SShare-300 Sets the display to 256 and Share to -44 (as expected) But this script: SShare=-256; Share = SShare-300 Unsets the display and sets the Share as -300, and evidently, 'SShare = -256' results in SShare equal to 0. If you are using: 'SShare = Share' to function like 'ABS(Share)', I think it will fail when Share < 0 Also important, the scripts are too long to use in the button hot keys. They work in the hot key file when assigned to a keyboard shortcut, but the buttons' text boxes, that holds the script, are limited to 200 characters.If you paste a 300 character script, only the first 200 characters are saved in the text box.
  16. This script was a revelation. Especially that there is some user space variables. Kudos Kyle and Franco!! The change to export to excel is simple. Excel, at least my version, does not translate the range formula "=$A$3:$D:3". Where there is a cell range in a formula replace it with each cell. For example: =$A$3:$D:$3 would be rewritten =$A$3, $B$3, $C$3, $D$3, The three formulas ( E11, E25 and E40) become: =CONCATENATE($A$3,$B$3,$C$3,$D$3, $E$3, B11, $G$3, IF(D11 = "long", " Ask - Price + ", " Price - Bid + "), $I$3, $J$3, "Share", $L$3, $M$3, $N$3, $O$3, IF(D11 = "long", " Ask + ", " Bid - "), $Q$3, $R$3, $S$3, $T$3, IF(D11 = "long", " BUY=", " SELL="), $V$3, $W$3, $X$3, $Y$3) =CONCATENATE($A$3, $B$3, B25, $G$3, IF(D25 = "long", " Ask - Price + ", " Price - Bid + "), $I$3, $J$3, $A25, $L$3, $M$3, $N$3, $O$3 , IF(D25 = "long", " Ask + ", " Bid - "), $Q$3, $R$3, $S$3, $T$3, IF(D25 = "long", " BUY=", " SELL=") , $V$3, $W$3, $X$3, $Y$3) =CONCATENATE($A$3, $B$3, ";Share=Pos;SShare=Share *", A40, $M$3, $N$3, $O$3 , IF(D40 = "long", " Ask + ", " Bid - "), $Q$3, $R$3, $S$3, $T$3, IF(D40 = "long", " BUY=", " SELL=") , $V$3, $W$3, $X$3, $Y$3) -- then copy each cell to the others -- For example copy E11 to E12 through E20, You can make the changes in google doc then download to excel.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.