Wireless Sensor Networks are networks for collecting environment information in a specific area using low power sensor nodes. The sensors sense different physical phenomena, and thus, are expected to have different sensing capabilities. The sensed data from the sensor nodes is communicated to the gateway of the network through intermediate nodes by various hops. This raw data has to be pre-processed to eradicate redundancy and the grains in the completeness of the data. This paper proposes a hybrid aggregation scheme called Spatio-Temporal Data Aggregation (STDA) that uses in-network aggregation and a set of novel data structures including a 3D data cube that minimize the redundant packet flow and number of messages passed in the network.