Another Bhavcopy Downloader (ABCD)

Are you trying ABCD or ABCDCurl?
Please check with ABCDCurl and let me know which modules are failing. I could download NSE equity, index and futures up to 9th April.

I am not using other modules
So did I. ABCDCurl is what I used. In fact, I downloaded the updated zip and ran it on another drive. It still couldn't download. I finally managed to download all the files but only by using the switch "-O' not lowercase"-o". In that case it downloaded to same folder as ABCDCurl but did not get processed further. I will do one thing, uninstall and reinstall ABCDCurl. Maybe then it might work.
 
Nevermind. I figured out what the issue was. I was working in the ABCDCurl folder.

The moment I copied the ABCDCurl.r file into the "ABCD" folder, everything worked. Some days from Cur and IRF are not downloading but almost all of it got downloaded. NSE Eq downloaded without an issue. I will tinker around a bit and report back once I am successfull. Over this weekend I want to add one more option to the software. Once done, I will share it here.

@josh1

Edit: @josh1 . made the necessary changes, everything works. Cur just has one issue. Must be a syntax error somewhere, after n number of days it just jumps out to the console window. i will dig around tomorrow and have a look. Till then everything else works. Thanks a lot.
 
Last edited:
This works amazingly well for BSE downloads. But for NSE downloads I keep getting this error:

Tried starting ABCD in admin mode but that also doesn't help.

@josh1 I have corrected this error. The correct date syntax was "date2" and not "Sd". Now the Currency segment is working fine too.

Edit2: There were some further edits to be made which were resulting in an empty NSECUR folder. I have taken that code from an older post here on the thread. Credits for NSECUR goes to that chap except for the part where i deleted the code for including active IRF contracts in the Currency segment itself and the option for options contracts.
 

Attachments

Last edited:

vicky_ag

Well-Known Member
@josh1 I have corrected this error. The correct date syntax was "date2" and not "Sd". Now the Currency segment is working fine too.

Edit2: There were some further edits to be made which were resulting in an empty NSECUR folder. I have taken that code from an older post here on the thread. Credits for NSECUR goes to that chap except for the part where i deleted the code for including active IRF contracts in the Currency segment itself and the option for options contracts.
Thank you. This works quite well.

A question though:
The bhavcopy data is amazing as it shows non-survivorship bias data. But then it also doesn't adjust for stock splits. so if I load into sql tables it ends up in a disaster. DIXON which split 10 from 2, the price data is incorrect. Any ideas on how to get stock split data from NSE?

Edit: It seems the combined report instead of bhavcopy does the trick. It contains the FV field which can be tracked and prices adjusted.
 
Last edited:
Stock Split, is better handled in charting software like Amibroker after data import.

1620250363002.png

Takes about 20sec time to generate the file, however, with verbose option ticked, I found the resulting file getting deleted automatically. ( bug ?? )

Tested AMFII module on ABCD, it still works, using the above setting, but only problem is it gets hung after the file download & fails to exit out of the routine, so can not exit ABCD, had to kill it in task manager. It takes a few minutes for the file to show up in the .\ABCD\AmfiMF folder though.

Joshiji, please fix this.

Note: If we tick the last box, it grabs all MF fund house data in a single txt file for the end-date. To download individual Fund House bulk data , we need to mention as seen below:

1620250620146.png

Downloaded data file format is as seen below:

1620251233475.png


When I tried to download last 20yr data at once, it grabbed the CSV as per verbose output, but failed to give final TXT file:

1620251328810.png


Above proves the fact AMFII URL is still good.

Attached is the list of all MF house codes to be used on MF_Numbers.txt file for bulk data download.

The downloaded txt file needs python processing to be made suitable for Amibroker though to conform to TIK,O,H,L,C format.
 

Attachments

Last edited:

TracerBullet

Well-Known Member
Thank you. This works quite well.

A question though:
The bhavcopy data is amazing as it shows non-survivorship bias data. But then it also doesn't adjust for stock splits. so if I load into sql tables it ends up in a disaster. DIXON which split 10 from 2, the price data is incorrect. Any ideas on how to get stock split data from NSE?

Edit: It seems the combined report instead of bhavcopy does the trick. It contains the FV field which can be tracked and prices adjusted.
Can you explain ? Eichermotors for example has Face value = 1.
That seems to be the only info we have, i also dont see historical combined report as link is https://www1.nseindia.com/content/combined_report.zip
How will you find past adjustments and corresponding dates through this ?
 

vicky_ag

Well-Known Member
Stock Split, is better handled in charting software like Amibroker after data import.
I don't use Amibroker instead load this to a table. still how do you handle it in Amibroker? Is it possible to share adjusted data by exporting it out of amibroker? Thanks in advance.

Can you explain ? Eichermotors for example has Face value = 1.
That seems to be the only info we have, i also dont see historical combined report as link is https://www1.nseindia.com/content/combined_report.zip
How will you find past adjustments and corresponding dates through this ?
Which file are you getting that FV info from? Because if you have that info it is more than enough. Just look at DIXON's FV on 17 Mar vs 18 Mar. You'll see the FV change from 10 to 2 on 18th i.e. the stock is split 1:5 on 18th Mar.

Check in the historical download page. Select combined report and date to download the combined report.
https://www1.nseindia.com/products/content/equities/equities/archieve_eq.htm
 

TracerBullet

Well-Known Member
I don't use Amibroker instead load this to a table. still how do you handle it in Amibroker? Is it possible to share adjusted data by exporting it out of amibroker? Thanks in advance.


Which file are you getting that FV info from? Because if you have that info it is more than enough. Just look at DIXON's FV on 17 Mar vs 18 Mar. You'll see the FV change from 10 to 2 on 18th i.e. the stock is split 1:5 on 18th Mar.

Check in the historical download page. Select combined report and date to download the combined report.
https://www1.nseindia.com/products/content/equities/equities/archieve_eq.htm
jackpot .. have a look at bhavcopy PR zip and within it Bcddmmyy.csv
"Bcddmmyy.csv file contains the corporate action details for securities."
dividend, split etc etc all there
 

vicky_ag

Well-Known Member
jackpot .. have a look at bhavcopy PR zip and within it Bcddmmyy.csv
"Bcddmmyy.csv file contains the corporate action details for securities."
dividend, split etc etc all there
Can you give an example? Because I tried looking up Dixon's split as an example. The split happened on 18th March but I don't see any corporate action in the Bc180320.csv or Bc170320.csv files.
My mistake. Needed to look into 21 instead of 20. Now need to find a way to download these files and process it to get the adjusted data.
 

Similar threads