Getting historical options data using bloomberg into excel - excel

I'm trying to get the option price from 11/8/17 to 14/8/17 with the 12/20/19 expiration for the 4200 put on the SX5E Index.
I wrote the code below but it gives me an N/A Invalid Field error.
=BDH("SX5E 12/20/19 P4200 Index",11/8/2017,14/8/2017)
I tried changing the dates around and adding a 0 before the 8 but it does not work and the security name is valid as I searched it on bloomberg and fixed an error that said it was invalid from before.

You haven't specified a field. Say you want to retrieve the daily price, you can use PX_LAST for example:
=BDH("SX5E 12/20/19 P4200 Index", "PX_LAST", 20170811, 20170814)
Also note that I'm not sure it will work with the date format you are using, I've changed it to yyyymmdd. Alternatively you can use references to other cells containing the dates you need.

Related

NetSuite Saved Search Calculate Date Difference Between Two Related Records

I'm trying to calculate the difference in days between an Invoice Date and the Date it was emailed out on a Saved Search.
I have a saved search created where I can see both the Invoice date (trandate) as well as the email date (messages.messagedate) but when I try to put this into a formula I keep getting a "field not found error".
I'm new to NetSuite and I also don't know a lot of SQL so I'm sure it's something basic I'm missing but here's what I have tried:
Formula (Date): TRUNC({messages.messageDate}-{transaction.tranDate}) || ' days '
Formula (Numeric): ROUND({message.messageddate}-{transaction.trandate})
I've tried "messages." and "message." and I've tried transaction. and without "transaction.".
I think I'm just missing the exact structure I need to use to reference the fields on two separate but connected records.
Please assist!
Please use Formula numeric and try with this formula
ABS(TO_DATE({messages.messagedate})-TO_DATE({trandate}))

Pulling historical options closing data given strike, expiration and date

I have a column of an option type I want(either call or put), a column for the date that I want the closing price of the option for,the option expiration date and the option strike. I want to find the option price on close given this information.
I wrote the formula below to try and find the price of the 3600 call on 3/8/19 with an expiration of 12/20/19 but it gives me an #N/A connection error.
=BDP("SX5E 12/20/19 C3600","px_last","03/08/2019","03/08/2019")
I expected to get what I described above but got an #N/A error
If you are interested in retrieving data that is historical (non current), then you would be better served by using the BDH formula, instead of BDP, which will give you the current value.
Perhaps this may help you
=BDH("SX5E 12/20/19 C3600 Index","px_last","03/08/2019") .
Notice how I added "Index" to the security name, to make it valid.

Multiple conditions finding median in Excel

I have included a link to a sample sheet. It contains home sales for 17 years and includes the property type (Type), price (SP), Value (Price/SQF), and Size (SQF). I want to find the median of each for every type, for every year, and for every month.
https://drive.google.com/file/d/1ecmNoQ5g3xr2GsaxeHwupq3Rqnu84puD/view?usp=sharing
I used this formula (for example) for finding the median value each year, but when I manually check it, it is incorrect: {=AGGREGATE(17,6,Value/((YEAR(Closing_Date)=$J127)*(Type="Condo")),2)}.
I really don't understand how that formula works (specifically, the "17,6" and the "2" at the end). I've tried using the =median with all the conditions but I get missing argument errors. Not sure what to do.
I've included space and allow editing of the test file if that helps. Once I see the formulas for one property type, I'll be able to replicate for the other 2 types.
picture of data file
{=AGGREGATE(17,6,Value/((YEAR(Closing_Date)=$J127)*(Type="Condo")),2)} is the right answer. After studying quartile.inc I realized I had a different error that was the causing the problem.

Can't convert Date to Number

I have a userform and I take start and end dates from user as in dd.mm.yyyy format. To make it easier to compare dates, I want to turn it to a double or long type of value. I have tried as in below but it gives me an error of type mismatch.
endDate is already defined as Double and as you can see, Me.g_end.Value is string in proper format. Why do I get this error, and how can I handle it?
Also I need to add, DateValue(Me.g_end.Value) works fine with my friend to get value of date who uses Excel 2013. I use Excel 2016.
You need to enter dates in a valid format in order for Excel to recognize them as dates.
As far as I know, nowhere uses dots (periods) in dates. (As I recall, nowadays only one country in the world even recognizes dots as am official date separator.)
Click your Start menu and type Region to find and open Windows Region and Language Settings.
Note the format that your system is expecting for Short Date, including the symbol between each date part, and try entering your dates in Excel like that.

Error in Calculated Column (using Today) in DataSheet View - Sharepoint 2010

I have calulated column which display's the value based on the difference between today and requested date field.
=Today-[Requested Date]
This is working fine in Sharepoint Standard View. But the same is not working with the datasheet view . The calculated column is showing as below
=#NAME?-[Requested Date].
Due to this i am not able to save the data. Can anyone please let me know how to solve this ?
Which SharePoint version are you using?
I tried the same scenario using SharePoint 2013 and was able to add the values in both standard and datasheet views. I am assuming you might have used the same steps.
Create 2 new columns named RequestedDate(DateTime) and
Today(Single line of text).
Add a new column of type calculated field with formula
=Today-[Requested Date].
Now delete the Today column.
Try entering the data in both the views.
First I have used today() function to calculate difference between 2 days except working days. The list is not automatically updating. If we change the Start_Date, then it calculates and gives the value. Can you suggest me why this happens?
You have mentioned in your post that there is some tricks in using today() function. I have created separate Today_Date column in my list. And Used the same column name in finding difference between 2 days. Here also the same problem exists.
The formula I used is,
=IF(AND((WEEKDAY([Today Date],2))<(WEEKDAY([Release Date],2)),((WEEKDAY([Release Date],2))-(WEEKDAY([Today Date],2)))>1),(((DATEDIF([Release Date],[Today Date],"D")+1))-(FLOOR((DATEDIF([Release Date],[Today Date],"D")+1)/7,1)*2)-2),(((DATEDIF([Release Date],[Today Date],"D")+1))-(FLOOR((DATEDIF([Release Date],[Today Date],"D")+1)/7,1)*2)))
Please tell me how to make the difference between 2 date values update automatically every time I open the list.
Then I tried the trick which you have mentioned above. But it works while I enter the data. When I open the list for the next day or some other day's after the Calculated column is not taking the current day's value, do the data remains same. what should I need to do in case it needs to take current date's value and calculate the formula?

Resources