excel-lent girl

New Member
Joined
Jun 22, 2012
Messages
4
I'm trying to do something with excel and I'm not quite sure it's possible.

I have data on a spread sheet ranging from 1:15

One step I have taken in what I want to do is having a formula to count the number of time a certain data input shows up:

=COUNTIFS('spread sheet'!1:15,"data 1")

But what I want to do now is have excel take all the variances where the value of "data 1" is true in a cell and then count the number of times "data 2" shows up in the cell below it... so that it will count the number of times 1 is followed by 2 (or 3 or 4 etc).

Is this possible?

Thanks!
 

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
I'm trying to do something with excel and I'm not quite sure it's possible.

I have data on a spread sheet ranging from 1:15

One step I have taken in what I want to do is having a formula to count the number of time a certain data input shows up:

=COUNTIFS('spread sheet'!1:15,"data 1")

But what I want to do now is have excel take all the variances where the value of "data 1" is true in a cell and then count the number of times "data 2" shows up in the cell below it... so that it will count the number of times 1 is followed by 2 (or 3 or 4 etc).

Is this possible?

Thanks!

Try to change

"data 1"

to

"data *".
 
Upvote 0
Try to change

"data 1"

to

"data *".

That won't return the information I need.

Example:

data 1 data 1 data 2 data 3 data 1
data 3 data 2 data 1 data 4 data 2
data 2 data 1 data 3 data 1 data 4
data 1 data 3 data 4 data 3 data 3
data 3 data 1 data 2 data 4 data 1
data 1 data 4 data 1 data 3 data 2

So if I used =COUNTIFS('spread sheet'!1:15,"data 1") I'd get a value of 11
If I used your suggestion =COUNTIFS('spread sheet'!1:15,"data *") I'd get a value of 30

What I want is a formula that will find each "data 1" and then look beneath it to see if the cell below it contains "data 2"... in this case it should return a value of 3
 
Upvote 0
Hi


<colgroup><col style="width: 28ptpx"><col width="60pt"><col width="60pt"><col width="60pt"><col width="60pt"><col width="60pt"><col width="60pt"><col width="60pt"><col width="60pt"><col width="60pt"></colgroup><tbody>
[TD="align: center"]A[/TD]
[TD="align: center"]B[/TD]
[TD="align: center"]C[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]E[/TD]
[TD="align: center"]F[/TD]
[TD="align: center"]G[/TD]
[TD="align: center"]H[/TD]
[TD="align: center"]I[/TD]

[TD="bgcolor: #cacaca, align: center"]1[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]

[TD="bgcolor: #cacaca, align: center"]2[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]

[TD="bgcolor: #cacaca, align: center"]3[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]

[TD="bgcolor: #cacaca, align: center"]4[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]

[TD="bgcolor: #cacaca, align: center"]5[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]

[TD="bgcolor: #cacaca, align: center"]6[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]

[TD="bgcolor: #cacaca, align: center"]7[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]

[TD="bgcolor: #cacaca, align: center"]8[/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: right"] [/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: right"]3[/TD]

</tbody>

ZelleFormel
I8=COUNTIFS(A1:E6,G8,A2:E7,H8)

<colgroup><col style="width: 40ptpx"><col></colgroup><tbody>
</tbody>
Diese Tabelle wurde mit Tab2Html (v2.4.1) erstellt. ©Gerd alias Bamberg

<tbody>
</tbody>
 
Upvote 0
Hi


<tbody>
[TD="align: center"]A[/TD]
[TD="align: center"]B[/TD]
[TD="align: center"]C[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]E[/TD]
[TD="align: center"]F[/TD]
[TD="align: center"]G[/TD]
[TD="align: center"]H[/TD]
[TD="align: center"]I[/TD]

[TD="bgcolor: #cacaca, align: center"]1[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="bgcolor: #cacaca, align: center"]2[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="bgcolor: #cacaca, align: center"]3[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="bgcolor: #cacaca, align: center"]4[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="bgcolor: #cacaca, align: center"]5[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="bgcolor: #cacaca, align: center"]6[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 4[/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 3[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="bgcolor: #cacaca, align: center"]7[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="bgcolor: #cacaca, align: center"]8[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: left"]data 1[/TD]
[TD="align: left"]data 2[/TD]
[TD="align: right"]3[/TD]

</tbody>

ZelleFormel
I8=COUNTIFS(A1:E6,G8,A2:E7,H8)

<tbody>
</tbody>
Diese Tabelle wurde mit Tab2Html (v2.4.1) erstellt. ©Gerd alias Bamberg

<tbody>
</tbody>

I'm sorry, this doesn't make much sense... and it's not the area I want to have targeted. I want all data looked at from rows 1-15.. because on my actual worksheet there is untold columns of information to sort through. I do not have the time to change the formula each time a new column is added.
 
Upvote 0

Forum statistics

Threads
1,223,231
Messages
6,170,884
Members
452,364
Latest member
springate

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