Extract a subset from a list

dsipp

New Member
Joined
Sep 17, 2011
Messages
16
Office Version
  1. 365
Platform
  1. Windows
I have a large linear list with three columns. First column is a date, second is a number and the third is curency. This table is charted to show a linear growth over time. Each week a new row is added to the list. I already have used the OFFSET formula to make the linear chart dynamic. What I am having trouble with is creating a sublist that extracts the data based on the year of the date in column A. VLOOKUP allowed me to get the sublist for the first year only. I am try to dynamically create data sets to chart the data to show comparison year over year. So all dates from 2008 create a series, 2009 creates a series and so on. I have tried MATCH, INDEX and other combinations. Am I making this harder than it is?
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
You can use a SUMPRODUCT() trick to count how many rows have the same year.
Excel Workbook
ABCD
11/1/2009
22/1/2009
33/1/2009
44/1/2009
55/1/2009200912
66/1/2009201012
77/1/200920112
88/1/2009
99/1/2009
1010/1/2009
1111/1/2009
1212/1/2009
131/1/2010
142/1/2010
153/1/2010
164/1/2010
175/1/2010
186/1/2010
197/1/2010
208/1/2010
219/1/2010
2210/1/2010
2311/1/2010
2412/1/2010
251/1/2011
261/2/2011
Sheet1



Does that help?
 
Upvote 0
Thank you for your reply. Although this is not the reult I am looking for. I want to extract all data from the main list and create a new listing. So if there were 20 rows for the year 2008, then I would get a new table with 20 entries.

Regards,
David
 
Upvote 0
If your dates are in ascending order in column A of Sheet1, maybe this to year = 2009

Names Manager > New
Name: Year2009
Refers to: =INDEX(Sheet1!$A$1:$A$26,MATCH(2009,YEAR(Sheet1!$A$1:$A$26),0)):INDEX(Sheet1!$A$1:$A$26,MATCH(2009,YEAR(Sheet1!$A$1:$A$26)))

You can create other names to Year 2010, 2011 etc changing the year in the formula
(i used the data provided by jbeaucaire)

M.
 
Upvote 0
There is a wrong space at the end of the formula

YEAR(Sheet1!$A$1:$A$2 6)))

The correct is

YEAR(Sheet1!$A$1:$A$26)))

M.
 
Upvote 0
Thanks for the reply. How would I go about using the result to build the 2nd list?
 
Upvote 0
yes. I want to use the other list as series for graphs.
 
Upvote 0
yes. I want to use the other list as series for graphs.

Say you need a dynamic range for 2010:

Names Manager > New
Name:Year2010
Refers to:
=INDEX(Sheet1!$A$1:$A$26,MATCH(2010,YEAR(Sheet1!$A$1:$A$26),0)):INDEX(Sheet1!$A$1:$A$26,MATCH(2010,YEAR(Sheet1!$A$1:$A$26)))


To get the data corresponding to year 2010
If, for example, the data corresponding to year 2010 is in column B you can use
Names Manager > New
Name: Data2010
refers to: =OFFSET(Year2010,0,1)

M.
 
Upvote 0
I guess I just do not understand where I would use the formulas you have created?

David
 
Upvote 0

Forum statistics

Threads
1,224,586
Messages
6,179,719
Members
452,939
Latest member
WCrawford

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top