Free data from NSENOW to AmiBroker via Excel

Status
Not open for further replies.

EagleOne

Well-Known Member
Hey josh, last night I went through your thread, and I got the whole thing working in Ami in no time. Thanks, mate. Great effort.

The only thing that sucked was the backfill. I tweaked this and tweaked that, and it worked in the end. But saala mazaa nahin aaya. BTW, does the backfill data come in 5 min interval or I made some mistake? I request SR114 to let me know if it is possible to have 1 min backfill data from Nest - also that semi-automatic method of backfilling.

Thanks to all you guys. Great stuff. :)
 

sr114

Well-Known Member
E1,

for me the backfill part really sucks. i do the backfill from my old and beloved DIET ODIN and its of 1 min tf.

this weekend i will try to tweak the backfill part and will let u know by Monday earliest.(actually working on it. if it is successful this night i will let u know)

do the following to get the 1 min time interval.
1. right click on any scrip in the market watch.
2. open plugin commands - plus charts
3.right click on the chart area and go to interval settings
the settings are - hourly, 30 min, 5 min , 1 min, configured.
4. configure 1 min time frame and you are done


regards
sr
 
Last edited:
Hey josh, last night I went through your thread, and I got the whole thing working in Ami in no time. Thanks, mate. Great effort.

The only thing that sucked was the backfill. I tweaked this and tweaked that, and it worked in the end. But saala mazaa nahin aaya. BTW, does the backfill data come in 5 min interval or I made some mistake? I request SR114 to let me know if it is possible to have 1 min backfill data from Nest - also that semi-automatic method of backfilling.

Thanks to all you guys. Great stuff. :)
Hi EagleOne, when you open the Nest chart, make the interval as 1 min and then open the data table, then data table will give 1min interval data and you can backfill this 1min data.
Thanks
 
Hi all,
First things first, let me thank Josh1 and other contributers for creating such a wonderful tool and sharing it with all of us.

Am facing some serious hurdles in backfilling the data. I have followed the instructions to the last word. Made two changes in the VBA part :
1) Providing the right path to NOW
2) Providing the right path to Amibroker

The data seems to be streaming fine into Amibroker, but backfill just isn't happening and I don't have the faintest clue why.

Am pasting the text from my NSENOW2.format file -

# Format definition file generated automatically
# by AmiBroker's ASCII Import Wizard
$FORMAT Date_MDY, Ticker, Time, Close, Volume, Appendticker, Appendticker
$SKIPLINES 1
$SEPARATOR ,
$CONT 1
$GROUP 255
$AUTOADD 1
$DEBUG 1

The original location of NowBackfil.xls is in E:\ whilst the autogenerated NowBackfil.xls and MyCSV.xls are created in C:\.

The original NowBackfil.xls in E:\ has the Masters tab where the location of the realtime database is mentioned whereas the duplicate NowBackfil.xls thats created in C:\ has only one tab named NowBackfil. When I click on the Backfil tab in NowBackfil.xls, it prompts me split date and save my Amibroker database and I do the same. Only issue is the backfill fails. I tried backfilling for Cairn and Cipla that are in the original sheet but even they failed to backfill. Is it because the Symbol in the Excel sheet is Cipla and the trading symbol that appears in the backfill data is Cipla-EQ? Well, even if that were the case, a new symbol by the name Cipla-EQ should have appeared in Amibroker so that I can merge the two symbols and complete the backfill.
Any help/pointers in this regard would be greatly appreciated.
 

josh1

Well-Known Member
Hi all,

The original location of NowBackfil.xls is in E:\ whilst the autogenerated NowBackfil.xls and MyCSV.xls are created in C:\.

Josh1

actually the date part sucks in backfilling. trying to backfill in the evening - tried twice but was struck in the middle. then reverted to my semi automatic backfilling which i do in 1 min.

so no question of backfilling headache with nowbackfill.xls

sr
Hi,
If it is possible, please
How to back fill from OHLC chart for toaday's data backfill,
This is the part in code where we are splitting date/time field.

If MsgBox("Do you want to split Date_Time into separate columns", vbYesNo) = vbYes Then
Application.DisplayAlerts = False
Columns("C:C").Select
Selection.Insert Shift:=xlToRight, CopyOrigin:=xlFormatFromLeftOrAbove
Columns("B:B").Select
Range("B1").Activate
Selection.Copy
Columns("C:C").Select
Range("C1").Activate
ActiveSheet.Paste
Columns("B:B").Select
Range("B1").Activate
Application.CutCopyMode = False
Selection.NumberFormat = "m/d/yyyy"
Columns("C:C").Select
Range("C1").Activa te
Selection.NumberFormat = "[$-F400]h:mm:ss AM/PM"

End If
You can try following things.
1.Comment out the red lines, control you date and time formats through Start-Control Panel-Regional and Language options-customize-date tab or time tab. Excel defaults to these formats.
2.Change the formats in above lines and try.
3.Open the NowBackfil.csv and see the date and time formats. Change the date format in Nest.format file to match it.
Please note that AmiBroker requires TIME time in HH:MM:SS or HH:MM or HHMM or HHMMSS format that means in 24 hour format only.
Please tell me which one is working well so that I can make changes in code.

In my case, I have kept interval of 1 Min. in NestPlus chart. I click on any scrip in market watch, Press Ctrl+P and Nestplus chart is generated. Click anywhere on the chart and Press Ctrl+D. Data table pops up. Click in the data table and Press Ctrl+A to select all or select whichever date range I want.(Data can be sorted by clicking on column headings). Then click on cell A1 in NowBackfill.xlsm Sheet1. If AmiBroker is open, save datbase. Click on Backfill. Takes less than 15 seconds for each scrip.

This is for FnO data. You can use DataDownloader made by Joydeep for cash scrip if you want to backfil bulk data. It can extract 10 days data from Google.

Newbie12345- We are not autogenerating any .xls files. NSE-NOW-RT2.1.xlsm and NOWBackfill.xlsm generate MyCSV.csv and NowBackfil.csv file respectively. Former are Excel files whiel the later are text files meant to be imported by AmiBroker.
 
Josh1

actually the date part sucks in backfilling. trying to backfill in the evening - tried twice but was struck in the middle. then reverted to my semi automatic backfilling which i do in 1 min.

so no question of backfilling headache with nowbackfill.xls

sr
Hi sr114, how did you backfill the data semi-automatically? My guess is you did it manually by tweaking it. Could you please elaborate a little and perhaps share the format file with us if you edited it as well. Thanks in advance.
 
Hi Josh1, am pasting the first few lines from the automatically generated backfill for Cipla -

CIPLA-EQ 14-05-2012 09:16:00 14-05-2012 09:16:00 318 318.7 317.1 317.5 4675
CIPLA-EQ 14-05-2012 09:17:00 14-05-2012 09:17:00 317.5 317.75 317.1 317.1 3511
CIPLA-EQ 14-05-2012 09:18:00 14-05-2012 09:18:00 317.1 317.45 317 317.2 2384
CIPLA-EQ 14-05-2012 09:19:00 14-05-2012 09:19:00 317.2 317.2 316.3 316.5 2933

Can you look at the data and tell where I might possibly be going wrong?

Much thanks!
 
Last edited:

sr114

Well-Known Member
Hi sr114, how did you backfill the data semi-automatically? My guess is you did it manually by tweaking it. Could you please elaborate a little and perhaps share the format file with us if you edited it as well. Thanks in advance.
Josh1 & Newbie12345

i mainly backfill commodity datas. in nest plus the interday data for 15 of commodities contains lot of zeroes in the o/h/l/c so nest plus is not suitable.

i take the backfill data from DIET ODIN - Market Movement and written a macro which does the necessary part like stripping unnecessary column, inserting today's date and import thru import wizard of Ami. the format file i use is the default 1 supplied with the utility.

if the backfill data are clean then nowbackfill.xls is the best choice.

if there is a wayso that i get clean data from nest plus i am with nowbackfill.xlm

sr114
 
Status
Not open for further replies.

Similar threads