简体   繁体   中英

Excel what method use to calculate time and age

I have got a table with 2 columns: AGE between 10 and 90 lets say :] and Time (spent on mobiles) What I need to do is- count how long people spent time on mobiles between 16 and 40. First part may be seemingly simple because we can count by countif how may people is using mobiles between 16 and 40 but how evaluate spend time on mobiles by the particular age groups. I will appreciate aaany help regards

If you need to analyze your data more than creating a static function to count, you may consider using Pivot tables.

Build a simple pivot table with age in rows and time in values. Once this simple pivot table built, you can filter on the rows values, group them together among specific grouping criteria, select specific values by hand, etc.

I like the idea given by Boud of using Pivots but if you specifically want a formula then you can use SumProduct()

=SUMPRODUCT((A2:A13>16)*(A2:A13<40)*(B2:B13))

Do remember to format the cell as [h]:mm:ss since you are adding up times.

SNAPSHOT

在此处输入图片说明

You can for example add additional column, with formula like:

=IF ( AND(A1>16, A1<40), B1, 0 )

where A is column with AGE, and B is column with Time, and then simply sum it!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM