Using the Federal Reserve Bank of St. Louis' Add-In, I am able to download historical rate data for multiple different securities (10-Year Treasury, 3-Month LIBOR, etc.) This is incredibly useful because I can update this data with by simply running the macro and it gives me all the historical data alongside the newest information.
The information looks like this after I run the Macro:
[TABLE="class: grid, width: 800"]
<tbody>[TR]
[TD="align: center"][/TD]
[TD="align: center"]A
[/TD]
[TD="align: center"]B
[/TD]
[TD="align: center"]C
[/TD]
[TD="align: center"]D
[/TD]
[/TR]
[TR]
[TD="align: center"]1
[/TD]
[TD="align: center"]DGS3MO[/TD]
[TD="align: center"][/TD]
[TD="align: center"]DGS1[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]2
[/TD]
[TD="align: center"]lin[/TD]
[TD="align: center"]Percent[/TD]
[TD="align: center"]lin[/TD]
[TD="align: center"]Percent[/TD]
[/TR]
[TR]
[TD="align: center"]3
[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]Daily[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]Daily[/TD]
[/TR]
[TR]
[TD="align: center"]4
[/TD]
[TD="align: center"]01/01/1900[/TD]
[TD="align: center"]1982-01-04 to 2015-02-18[/TD]
[TD="align: center"]01/01/1900[/TD]
[TD="align: center"]1962-01-02 to 2015-02-18[/TD]
[/TR]
[TR]
[TD="align: center"]5
[/TD]
[TD="align: center"]3-Month Treasury[/TD]
[TD="align: center"][/TD]
[TD="align: center"]1-Year Treasury[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]6
[/TD]
[TD="align: center"]Board of Governors[/TD]
[TD="align: center"][/TD]
[TD="align: center"]Board of Governors[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]7
[/TD]
[TD="align: center"]Date[/TD]
[TD="align: center"]Value[/TD]
[TD="align: center"]Date
[/TD]
[TD="align: center"]Value
[/TD]
[/TR]
[TR]
[TD="align: center"]8
[/TD]
[TD="align: center"]01/04/1982[/TD]
[TD="align: center"]11.9[/TD]
[TD="align: center"]01/02/1962[/TD]
[TD="align: center"]4.1[/TD]
[/TR]
[TR]
[TD="align: center"]9
[/TD]
[TD="align: center"]01/05/1982[/TD]
[TD="align: center"]12.2[/TD]
[TD="align: center"]01/03/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]10
[/TD]
[TD="align: center"]01/06/1982[/TD]
[TD="align: center"]12.2[/TD]
[TD="align: center"]01/04/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]11
[/TD]
[TD="align: center"]01/07/1982[/TD]
[TD="align: center"]12.2[/TD]
[TD="align: center"]01/05/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]12
[/TD]
[TD="align: center"]01/08/1982[/TD]
[TD="align: center"]12.0[/TD]
[TD="align: center"]01/06/1962[/TD]
[TD="align: center"]5.0[/TD]
[/TR]
[TR]
[TD="align: center"]13
[/TD]
[TD="align: center"]01/09/1982[/TD]
[TD="align: center"]12.3[/TD]
[TD="align: center"]01/07/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]14
[/TD]
[TD="align: center"]etc...[/TD]
[TD="align: center"]etc...[/TD]
[TD="align: center"]etc...[/TD]
[TD="align: center"]etc...[/TD]
[/TR]
</tbody>[/TABLE]
The data extends all the way down until the date with the latest information.
On a different tab, I need to be able to lookup what the maximum date in each range is and corresponding value next to it by identifying date column/corresponding value column via the codes present in A1 (DGS3MO) and A3 (DGS1). Of course, it has to adapt to when I update the macro and new dates and values are added. In addition, I have a bunch more rates than what I have shown in the example, so it would be great if the formulas wouldn't be restricted to just these four columns, but also included the ability to adapt to adding new columns as well.
I've tried a variety of different vlookup, hlookup, and index/match combinations but just haven't been able to get it to work. Any help would be GREATLY appreciated. Thank you so much!
The information looks like this after I run the Macro:
[TABLE="class: grid, width: 800"]
<tbody>[TR]
[TD="align: center"][/TD]
[TD="align: center"]A
[/TD]
[TD="align: center"]B
[/TD]
[TD="align: center"]C
[/TD]
[TD="align: center"]D
[/TD]
[/TR]
[TR]
[TD="align: center"]1
[/TD]
[TD="align: center"]DGS3MO[/TD]
[TD="align: center"][/TD]
[TD="align: center"]DGS1[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]2
[/TD]
[TD="align: center"]lin[/TD]
[TD="align: center"]Percent[/TD]
[TD="align: center"]lin[/TD]
[TD="align: center"]Percent[/TD]
[/TR]
[TR]
[TD="align: center"]3
[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]Daily[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]Daily[/TD]
[/TR]
[TR]
[TD="align: center"]4
[/TD]
[TD="align: center"]01/01/1900[/TD]
[TD="align: center"]1982-01-04 to 2015-02-18[/TD]
[TD="align: center"]01/01/1900[/TD]
[TD="align: center"]1962-01-02 to 2015-02-18[/TD]
[/TR]
[TR]
[TD="align: center"]5
[/TD]
[TD="align: center"]3-Month Treasury[/TD]
[TD="align: center"][/TD]
[TD="align: center"]1-Year Treasury[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]6
[/TD]
[TD="align: center"]Board of Governors[/TD]
[TD="align: center"][/TD]
[TD="align: center"]Board of Governors[/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]7
[/TD]
[TD="align: center"]Date[/TD]
[TD="align: center"]Value[/TD]
[TD="align: center"]Date
[/TD]
[TD="align: center"]Value
[/TD]
[/TR]
[TR]
[TD="align: center"]8
[/TD]
[TD="align: center"]01/04/1982[/TD]
[TD="align: center"]11.9[/TD]
[TD="align: center"]01/02/1962[/TD]
[TD="align: center"]4.1[/TD]
[/TR]
[TR]
[TD="align: center"]9
[/TD]
[TD="align: center"]01/05/1982[/TD]
[TD="align: center"]12.2[/TD]
[TD="align: center"]01/03/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]10
[/TD]
[TD="align: center"]01/06/1982[/TD]
[TD="align: center"]12.2[/TD]
[TD="align: center"]01/04/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]11
[/TD]
[TD="align: center"]01/07/1982[/TD]
[TD="align: center"]12.2[/TD]
[TD="align: center"]01/05/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]12
[/TD]
[TD="align: center"]01/08/1982[/TD]
[TD="align: center"]12.0[/TD]
[TD="align: center"]01/06/1962[/TD]
[TD="align: center"]5.0[/TD]
[/TR]
[TR]
[TD="align: center"]13
[/TD]
[TD="align: center"]01/09/1982[/TD]
[TD="align: center"]12.3[/TD]
[TD="align: center"]01/07/1962[/TD]
[TD="align: center"]4.0[/TD]
[/TR]
[TR]
[TD="align: center"]14
[/TD]
[TD="align: center"]etc...[/TD]
[TD="align: center"]etc...[/TD]
[TD="align: center"]etc...[/TD]
[TD="align: center"]etc...[/TD]
[/TR]
</tbody>[/TABLE]
The data extends all the way down until the date with the latest information.
On a different tab, I need to be able to lookup what the maximum date in each range is and corresponding value next to it by identifying date column/corresponding value column via the codes present in A1 (DGS3MO) and A3 (DGS1). Of course, it has to adapt to when I update the macro and new dates and values are added. In addition, I have a bunch more rates than what I have shown in the example, so it would be great if the formulas wouldn't be restricted to just these four columns, but also included the ability to adapt to adding new columns as well.
I've tried a variety of different vlookup, hlookup, and index/match combinations but just haven't been able to get it to work. Any help would be GREATLY appreciated. Thank you so much!