Need formula for creating Heatmap log files

sherpadude

New Member
Joined
Feb 23, 2010
Messages
5
I'm using excel 2007 and I'm trying to create heat map of system utilization. This is the first step (I will pivot data later to create map) - at the moment I'm just trying to understand the formula I need.

I believe I'm coming at this from a very low tech approach that will require a pretty extensive conditional formula but perhaps this is the only way.

http://picasaweb.google.com/lh/photo/SAm8IvJTWh4T5Ost5ymBKw?feat=directlink

this above screen shot shows the formula. I basically trying to get the amount of minutes in each hour that a log entry takes

for instance if a event goes on from 1:10pm to 2:10pm I would want 50minutes to show up in the 1pm hour and 10minutes to show up in the 2pm hour..

thanks for any help pointing in the right direction...
 
Last edited:

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Using your screen shot as an example:

K2: =MAX(0,MIN(K$1+"1:00",$F2)-MAX(K$1,$E2))
copied across matrix

Excel Workbook
EFGKLMNOPQR
100:0001:0002:0003:0004:0005:0006:0007:00
204:3704:510.009722 00:14
304:3704:510.00972200:14
404:3704:510.00972200:14
504:3705:510.05138900:2300:51
603:2307:340.17430600:3701:0001:0001:0000:34
Sheet1


resulting values will be Time (Decimal) and should be formatted accordingly (in above time format of h:mm;; is applied)
 
Upvote 0
WOW... simple, elegant, complex....
Thanks so much for that.. I owe a few solutions on this board as well - you should have seen the mess that I was creating!:) This saved me (my client) thousands of dollars in effort!
 
Upvote 0
no different (formatting general) but this variant works
=MAX(0,MIN(O1+"1:00",F2)-MAX(O1, "4:37")) - for O2 (the cell that should show a value for row 2...

apparently the formating E2 value is breaking it I guess.
 
Upvote 0
My point was/is ... if you format E2:F2 as General and inspect the resulting numbers I suspect you will find you have an Integer & Decimal not just Decimal (ie they are datetime stamps not time)

If so you need to adjust references references such that you use the Time portion (decimal) only:

=MAX(0,MIN(K$1+"1:00",MOD($F2,1))-MAX(K$1,MOD($E2,1)))

This also raises the issue of whether or not the End Time crosses midnight from Start Time (ie Decimal of F is less than Decimal of E) ... if so the above won't work in those circumstances and will require further adjustment.
 
Upvote 0
:-> great points, I was thinking about the midnight issue as well, you have certainly given me enough to work through I would never thought to approach it this way - My approach was much more convoluted - I'm going to see if I can solve with the base you have given me, thanks again!
 
Upvote 0

Forum statistics

Threads
1,214,847
Messages
6,121,911
Members
449,054
Latest member
luca142

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