I'm glad that the summary function was of help. You mentioned you calculate the mean over the rounded timestamps. therefore you get the means just for those rounded timestamps. What I'm confused about is your comment on "the means are off a bit because the timestamps do not align". What do you expect from the mean to look like? Do you have comparison values or do you mean it would be good to have a mean for every exact time stamp?
I'm happy with how the table looks. The numbers in the columns are off though. TagID 3322 does not have a timestamp at 4:10 PM, but when I do the mean function a SampleValue is in the 4:10 PM row. For the 4:20 PM timestamp, the SampleValue mean is not correct for the 3322 Tag. It averages the values for one of the 4:20 timestamps and one of the 4:30 timestamps.