How many rows between each data point in a column

William53

New Member
Joined
Jul 8, 2017
Messages
37
Office Version
  1. 365
Platform
  1. Windows
Hi All
I have been trying to grapple with the following problem for a few hours over the last few weeks. I have a list of weekly shopping amounts for the last 8/9 years. I have created a list of unique costs and then counted those to give me an idea of what is the most cost etc. What I want to do is count the weeks or rows between each cost. So, if it £90 in week 1, how many weeks or rows did £90 appear again throughout the data set?
I have tried to modify this formula "=LET(rowdiffs,FILTER(ROW(E2:E900)-1,E2:E900<>"")-FILTER(ROW(E1:E900),E1:E900<>""),INDEX(rowdiffs,SEQUENCE(ROWS(rowdiffs)-1)))", which was given to me by another forum member (KRice) to solve a football problem which worked when counting blank cells between entries, but cannot seem to get the same results if I ask for a specific amount like the £90 problem.
I have attached most of the data set but not all due to limit.
Goods Cost.xlsx
ABCD
2DateTotal CostSorted UniqueTimes Spent
313-Feb-04£ 154.00451
420-Feb-04£ 156.00461
527-Feb-04£ 119.00511
65-Mar-04£ 120.00521
712-Mar-04£ 158.00562
819-Mar-04£ 193.00573
926-Mar-04£ 83.00602
102-Apr-04£ 103.00612
119-Apr-04£ 57.00621
1216-Apr-04£ 132.00641
1323-Apr-04£ 131.00661
1430-Apr-04£ 77.00672
157-May-04£ 126.00681
1614-May-04£ 96.00691
1721-May-04£ 169.00706
1828-May-04£ 137.00712
194-Jun-04£ 139.00722
2011-Jun-04£ 74.00749
2118-Jun-04£ 136.00754
2225-Jun-04£ 123.00762
232-Jul-04£ 113.00775
249-Jul-04£ 82.00793
2516-Jul-04£ 169.00803
2623-Jul-04£ 109.00817
2730-Jul-04£ 125.00824
286-Aug-04£ 123.00839
2913-Aug-04£ 181.00846
3020-Aug-04£ 87.00855
3127-Aug-04£ 106.00867
323-Sep-04£ 83.00875
3310-Sep-04£ 137.00887
3417-Sep-04£ 142.00896
3524-Sep-04£ 166.00902
361-Oct-04£ 146.00915
378-Oct-04£ 87.00927
3815-Oct-04£ 137.00937
3922-Oct-04£ 98.00944
4029-Oct-04£ 114.00956
415-Nov-04£ 141.009611
4212-Nov-04£ 72.00979
4319-Nov-04£ 119.00987
4426-Nov-04£ 99.00996
453-Dec-04£ 118.0010010
4610-Dec-04£ 76.0010111
4717-Dec-04£ 151.0010215
4824-Dec-04£ 100.0010311
4931-Dec-04£ 111.001047
507-Jan-05£ 150.001054
5114-Jan-05£ 79.0010610
5221-Jan-05£ 86.0010713
5328-Jan-05£ 142.001088
544-Feb-05£ 90.0010912
5511-Feb-05£ 131.001107
5618-Feb-05£ 145.0011112
5725-Feb-05£ 147.0011211
584-Mar-05£ 144.0011318
5911-Mar-05£ 126.0011413
6018-Mar-05£ 159.001157
6125-Mar-05£ 141.0011610
621-Apr-05£ 183.001178
638-Apr-05£ 124.0011810
6415-Apr-05£ 145.0011913
6522-Apr-05£ 97.0012015
6629-Apr-05£ 128.0012110
676-May-05£ 110.0012210
6813-May-05£ 132.0012322
6920-May-05£ 101.001248
7027-May-05£ 155.0012514
713-Jun-05£ 89.0012611
7210-Jun-05£ 129.001275
7317-Jun-05£ 61.0012816
7424-Jun-05£ 88.0012912
751-Jul-05£ 85.001305
768-Jul-05£ 208.0013116
7715-Jul-05£ 89.0013223
7822-Jul-05£ 155.0013311
7929-Jul-05£ 147.0013415
805-Aug-05£ 86.0013513
8112-Aug-05£ 145.001369
8219-Aug-05£ 136.0013715
8326-Aug-05£ 154.0013811
842-Sep-05£ 114.0013918
859-Sep-05£ 120.001408
8616-Sep-05£ 103.0014110
8723-Sep-05£ 139.0014215
8830-Sep-05£ 162.0014315
897-Oct-05£ 106.0014410
9014-Oct-05£ 83.0014514
9121-Oct-05£ 96.0014610
9228-Oct-05£ 191.0014712
934-Nov-05£ 179.0014811
9411-Nov-05£ 150.0014910
9518-Nov-05£ 142.001506
9625-Nov-05£ 120.0015110
972-Dec-05£ 83.001528
989-Dec-05£ 144.001534
9916-Dec-05£ 70.0015410
10023-Dec-05£ 161.0015512
10130-Dec-05£ 131.001569
1026-Jan-06£ 57.001578
10313-Jan-06£ 106.0015811
10420-Jan-06£ 154.0015911
10527-Jan-06£ 134.001606
1063-Feb-06£ 149.0016112
10710-Feb-06£ 147.001628
10817-Feb-06£ 115.001637
10924-Feb-06£ 96.001643
1103-Mar-06£ 70.001654
11110-Mar-06£ 149.001664
11217-Mar-06£ 176.001674
11324-Mar-06£ 160.001683
11431-Mar-06£ 149.001696
1157-Apr-06£ 148.001701
11614-Apr-06£ 160.001717
11721-Apr-06£ 126.001734
11828-Apr-06£ 87.001743
1195-May-06£ 92.001765
12012-May-06£ 132.001771
12119-May-06£ 116.001782
12226-May-06£ 125.001796
1232-Jun-06£ 131.001801
1249-Jun-06£ 103.001814
12516-Jun-06£ 109.001824
12623-Jun-06£ 147.001834
12730-Jun-06£ 120.001842
1287-Jul-06£ 112.001852
12914-Jul-06£ 92.001871
13021-Jul-06£ 103.001881
13128-Jul-06£ 95.001891
1324-Aug-06£ 88.001902
13311-Aug-06£ 179.001912
13418-Aug-06£ 178.001922
13525-Aug-06£ 173.001933
1361-Sep-06£ 130.001942
1378-Sep-06£ 88.001972
13815-Sep-06£ 107.001992
13922-Sep-06£ 163.002001
14029-Sep-06£ 52.002011
1416-Oct-06£ 111.002021
14213-Oct-06£ 138.002081
14320-Oct-06£ 155.002121
14427-Oct-06£ 109.002171
1453-Nov-06£ 141.000
14610-Nov-06£ 128.00
14717-Nov-06£ 135.00
14824-Nov-06£ 95.00
1491-Dec-06£ 106.00
1508-Dec-06£ 134.00
15115-Dec-06£ 146.00
15222-Dec-06£ 121.00
15329-Dec-06£ 77.00
1545-Jan-07£ 146.00
15512-Jan-07£ 77.00
15619-Jan-07£ 120.00
15726-Jan-07£ 117.00
1582-Feb-07£ 130.00
1599-Feb-07£ 142.00
16016-Feb-07£ 136.00
16123-Feb-07£ 77.00
1622-Mar-07£ 139.00
1639-Mar-07£ 121.00
16416-Mar-07£ 143.00
16523-Mar-07£ 118.00
16630-Mar-07£ 132.00
1676-Apr-07£ 156.00
16813-Apr-07£ 131.00
16920-Apr-07£ 167.00
17027-Apr-07£ 132.00
1714-May-07£ 144.00
17211-May-07£ 123.00
17318-May-07£ 185.00
17425-May-07£ 179.00
1751-Jun-07£ 148.00
1768-Jun-07£ 103.00
17715-Jun-07£ 87.00
17822-Jun-07£ 100.00
17929-Jun-07£ 126.00
1806-Jul-07£ 108.00
18113-Jul-07£ 116.00
18220-Jul-07£ 132.00
18327-Jul-07£ 96.00
1843-Aug-07£ 151.00
18510-Aug-07£ 197.00
18617-Aug-07£ 98.00
18724-Aug-07£ 110.00
18831-Aug-07£ 106.00
1897-Sep-07£ 114.00
19014-Sep-07£ 87.00
19121-Sep-07£ 122.00
19228-Sep-07£ 165.00
1935-Oct-07£ 137.00
19412-Oct-07£ 182.00
19519-Oct-07£ 134.00
19626-Oct-07£ 148.00
1972-Nov-07£ 96.00
1989-Nov-07£ 102.00
19916-Nov-07£ 120.00
20023-Nov-07£ 111.00
20130-Nov-07£ 119.00
2027-Dec-07£ 129.00
20314-Dec-07£ 143.00
20421-Dec-07£ 125.00
20528-Dec-07£ 139.00
2064-Jan-08£ 112.00
20711-Jan-08£ 167.00
20818-Jan-08£ 139.00
20925-Jan-08£ 81.00
2101-Feb-08£ 193.00
2118-Feb-08£ 157.00
21215-Feb-08£ 159.00
21322-Feb-08£ 159.00
21429-Feb-08£ 185.00
2157-Mar-08£ 75.00
21614-Mar-08£ 142.00
21721-Mar-08£ 88.00
21828-Mar-08£ 99.00
2194-Apr-08£ 126.00
22011-Apr-08£ 156.00
22118-Apr-08£ 93.00
22225-Apr-08£ 106.00
2232-May-08£ 158.00
2249-May-08£ 144.00
22516-May-08£ 93.00
22623-May-08£ 92.00
22730-May-08£ 95.00
2286-Jun-08£ 137.00
22913-Jun-08£ 160.00
23020-Jun-08£ 137.00
23127-Jun-08£ 145.00
2324-Jul-08£ 123.00
23311-Jul-08£ 89.00
23418-Jul-08£ 113.00
23525-Jul-08£ 86.00
2361-Aug-08£ 138.00
2378-Aug-08£ 85.00
23815-Aug-08£ 103.00
23922-Aug-08£ 152.00
24029-Aug-08£ 123.00
2415-Sep-08£ 91.00
24212-Sep-08£ 162.00
24319-Sep-08£ 100.00
24426-Sep-08£ 144.00
2453-Oct-08£ 97.00
24610-Oct-08£ 113.00
24717-Oct-08£ 117.00
24824-Oct-08£ 100.00
24931-Oct-08£ 121.00
2507-Nov-08£ 57.00
25114-Nov-08£ 79.00
25221-Nov-08£ 143.00
25328-Nov-08£ 101.00
2545-Dec-08£ 113.00
25512-Dec-08£ 140.00
25619-Dec-08£ 193.00
25726-Dec-08£ 123.00
2582-Jan-09£ 180.00
2599-Jan-09£ 120.00
26016-Jan-09£ 141.00
26123-Jan-09£ 190.00
26230-Jan-09£ 148.00
2636-Feb-09£ 136.00
26413-Feb-09£ 173.00
26520-Feb-09£ 96.00
26627-Feb-09£ 140.00
2676-Mar-09£ 109.00
26813-Mar-09£ 140.00
26920-Mar-09£ 117.00
27027-Mar-09£ 174.00
2713-Apr-09£ 124.00
27210-Apr-09£ 122.00
27317-Apr-09£ 123.00
27424-Apr-09£ 104.00
2751-May-09£ 140.00
2768-May-09£ 111.00
27715-May-09£ 107.00
27822-May-09£ 107.00
27929-May-09£ 121.00
2805-Jun-09£ 131.00
28112-Jun-09£ 120.00
28219-Jun-09£ 86.00
28326-Jun-09£ 107.00
2843-Jul-09£ 177.00
28510-Jul-09£ 130.00
28617-Jul-09£ 109.00
28724-Jul-09£ 136.00
28831-Jul-09£ 81.00
2897-Aug-09£ 107.00
29014-Aug-09£ 116.00
29121-Aug-09£ 100.00
29228-Aug-09£ 171.00
2934-Sep-09£ 112.00
29411-Sep-09£ 147.00
29518-Sep-09£ 131.00
29625-Sep-09£ 96.00
2972-Oct-09£ 142.00
2989-Oct-09£ 143.00
29916-Oct-09£ 143.00
30023-Oct-09£ 104.00
30130-Oct-09£ 155.00
3026-Nov-09£ 152.00
30313-Nov-09£ 111.00
30420-Nov-09£ 132.00
30527-Nov-09£ 74.00
3064-Dec-09£ 136.00
30711-Dec-09£ 194.00
30818-Dec-09£ 160.00
30925-Dec-09£ 74.00
3101-Jan-10£ 118.00
3118-Jan-10£ 113.00
31215-Jan-10£ 165.00
31322-Jan-10£ 133.00
31429-Jan-10£ 138.00
3155-Feb-10£ 192.00
31612-Feb-10£ 107.00
31719-Feb-10£ 161.00
31826-Feb-10£ 107.00
3195-Mar-10£ 141.00
32012-Mar-10£ 142.00
32119-Mar-10£ 145.00
32226-Mar-10£ 122.00
3232-Apr-10£ 125.00
3249-Apr-10£ 119.00
32516-Apr-10£ 103.00
32623-Apr-10£ 107.00
32730-Apr-10£ 113.00
3287-May-10£ 77.00
32914-May-10£ 139.00
33021-May-10£ 144.00
33128-May-10£ 109.00
3324-Jun-10£ 137.00
33311-Jun-10£ 128.00
33418-Jun-10£ 132.00
33525-Jun-10£ 86.00
3362-Jul-10£ 148.00
3379-Jul-10£ 158.00
33816-Jul-10£ 217.00
33923-Jul-10£ 135.00
34030-Jul-10£ 85.00
3416-Aug-10£ 137.00
34213-Aug-10£ 96.00
34320-Aug-10£ 145.00
34427-Aug-10£ 99.00
3453-Sep-10£ 159.00
34610-Sep-10£ 159.00
34717-Sep-10£ 161.00
34824-Sep-10£ 109.00
3491-Oct-10£ 86.00
3508-Oct-10£ 159.00
35115-Oct-10£ 150.00
35222-Oct-10£ 68.00
35329-Oct-10£ 132.00
3545-Nov-10£ 167.00
35512-Nov-10£ 125.00
35619-Nov-10£ 140.00
35726-Nov-10£ 163.00
3583-Dec-10£ 133.00
35910-Dec-10£ 94.00
36017-Dec-10£ 129.00
36124-Dec-10£ 181.00
36231-Dec-10£ 141.00
3637-Jan-11£ 153.00
36414-Jan-11£ 123.00
36521-Jan-11£ 66.00
36628-Jan-11£ 143.00
3674-Feb-11£ 119.00
36811-Feb-11£ 83.00
36918-Feb-11£ 114.00
37025-Feb-11£ 160.00
3714-Mar-11£ 132.00
37211-Mar-11£ 143.00
37318-Mar-11£ 110.00
37425-Mar-11£ 99.00
3751-Apr-11£ 97.00
3768-Apr-11£ 179.00
37715-Apr-11£ 111.00
37822-Apr-11£ 162.00
37929-Apr-11£ 159.00
3806-May-11£ 97.00
38113-May-11£ 120.00
38220-May-11£ 111.00
38327-May-11£ 128.00
3843-Jun-11£ 182.00
38510-Jun-11£ 127.00
38617-Jun-11£ 114.00
38724-Jun-11£ 112.00
3881-Jul-11£ 119.00
3898-Jul-11£ 137.00
39015-Jul-11£ 138.00
39122-Jul-11£ 141.00
39229-Jul-11£ 133.00
3935-Aug-11£ 111.00
39412-Aug-11£ 101.00
39519-Aug-11£ 95.00
39626-Aug-11£ 137.00
3972-Sep-11£ 157.00
3989-Sep-11£ 119.00
39916-Sep-11£ 108.00
40023-Sep-11£ 135.00
40130-Sep-11£ 123.00
4027-Oct-11£ 158.00
40314-Oct-11£ 143.00
40421-Oct-11£ 137.00
40528-Oct-11£ 142.00
4064-Nov-11£ 159.00
40711-Nov-11£ 76.00
40818-Nov-11£ 123.00
40925-Nov-11£ 121.00
4102-Dec-11£ 147.00
4119-Dec-11£ 153.00
41216-Dec-11£ 71.00
41323-Dec-11£ 102.00
41430-Dec-11£ 189.00
4156-Jan-12£ 60.00
41613-Jan-12£ 114.00
41720-Jan-12£ 89.00
41827-Jan-12£ 125.00
4193-Feb-12£ 108.00
42010-Feb-12£ 97.00
42117-Feb-12£ 128.00
42224-Feb-12£ 82.00
4232-Mar-12£ 96.00
4249-Mar-12£ 157.00
42516-Mar-12£ 92.00
42623-Mar-12£ 128.00
42730-Mar-12£ 126.00
4286-Apr-12£ 141.00
42913-Apr-12£ 129.00
43020-Apr-12£ 111.00
43127-Apr-12£ 156.00
4324-May-12£ 149.00
43311-May-12£ 113.00
43418-May-12£ 182.00
43525-May-12£ 164.00
4361-Jun-12£ 82.00
4378-Jun-12£ 112.00
43815-Jun-12£ 145.00
43922-Jun-12£ 143.00
44029-Jun-12£ 127.00
4416-Jul-12£ 183.00
44213-Jul-12£ 132.00
44320-Jul-12£ 146.00
44427-Jul-12£ 121.00
4453-Aug-12£ 181.00
44610-Aug-12£ 147.00
44717-Aug-12£ 149.00
44824-Aug-12£ 79.00
44931-Aug-12£ 156.00
4507-Sep-12£ 135.00
45114-Sep-12£ 107.00
45221-Sep-12£ 141.00
45328-Sep-12£ 132.00
4545-Oct-12£ 83.00
45512-Oct-12£ 108.00
45619-Oct-12£ 166.00
45726-Oct-12£ 85.00
4582-Nov-12£ 74.00
4599-Nov-12£ 132.00
46016-Nov-12£ 108.00
46123-Nov-12£ 81.00
46230-Nov-12£ 115.00
4637-Dec-12£ 117.00
46414-Dec-12£ 133.00
46521-Dec-12£ 112.00
46628-Dec-12£ 143.00
4674-Jan-13£ 104.00
46811-Jan-13£ 133.00
46918-Jan-13£ 126.00
47025-Jan-13£ 99.00
4711-Feb-13£ 135.00
4728-Feb-13£ 112.00
47315-Feb-13£ 98.00
47422-Feb-13£ 132.00
4751-Mar-13£ 119.00
4768-Mar-13£ 116.00
47715-Mar-13£ 102.00
47822-Mar-13£ 154.00
47929-Mar-13£ 176.00
4805-Apr-13£ 100.00
48112-Apr-13£ 103.00
48219-Apr-13£ 145.00
48326-Apr-13£ 129.00
4843-May-13£ 131.00
48510-May-13£ 161.00
48617-May-13£ 125.00
48724-May-13£ 113.00
48831-May-13£ 161.00
4897-Jun-13£ 142.00
49014-Jun-13£ 171.00
49121-Jun-13£ 132.00
49228-Jun-13£ 126.00
4935-Jul-13£ 92.00
49412-Jul-13£ 151.00
49519-Jul-13£ 114.00
49626-Jul-13£ 151.00
4972-Aug-13£ 184.00
4989-Aug-13£ 67.00
49916-Aug-13£ 147.00
50023-Aug-13£ 100.00
50130-Aug-13£ 125.00
5026-Sep-13£ 128.00
50313-Sep-13£ 84.00
50420-Sep-13£ 134.00
50527-Sep-13£ 148.00
5064-Oct-13£ 135.00
50711-Oct-13£ 101.00
50818-Oct-13£ 159.00
50925-Oct-13£ 84.00
5101-Nov-13£ 118.00
5118-Nov-13£ 168.00
51215-Nov-13£ 102.00
51322-Nov-13£ 154.00
51429-Nov-13£ 85.00
5156-Dec-13£ 88.00
51613-Dec-13£ 101.00
51720-Dec-13£ 107.00
51827-Dec-13£ 70.00
Bought Goods
Cell Formulas
RangeFormula
C3:C145C3=SORT(UNIQUE(B3:B991))
D3:D144D3=COUNTIF($B$3:$B$991,C3)
Dynamic array formulas.
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
How about
Excel Formula:
=LET(a,FILTER(ROW($B$3:$B$1000),($B$3:$B$1000=C3)*(C3<>0),""),IF(ROWS(a)=1,0,TEXTJOIN(", ",,DROP(a,1)-DROP(a,-1))))
 
Upvote 0
Solution
Hi Fluff
Wow it works but I haven't got a clue how!!:) Never heard of DROP.
Thank you so much for your time, really is appreciated.
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,943
Messages
6,122,370
Members
449,080
Latest member
Armadillos

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