Average value in material nodes
I think there is an issue with your premise. The Average Value node works in the compositor by performing operations on a bounded, finite image, with the resolution you set in the Render settings. 

In material nodes, however, the vectors you use, and by extension, the colors, are in an infinite vector space. Not only that, but they aren't (by default) quantized. In compositing, there is a finite number of pixels, making it easy to average the image. In material nodes, you can keep zooming in forever, making it much trickier to get an average value1. 

So, the answer to your question is that it isn't possible, because material nodes don't work the same way as compositing. If you ask a new question with a more specific problem, though, we might be able to help you find a way to do what you want to do.



1While it is (sometimes) mathematically possible to find an average value over an infinite vector space with calculus, I suspect that would be very tricky to implement in nodes (and probably impossible without OSL).