Fixed new query() method for AAGCloudSensor and tracked down resulting bugs and flaws.

Tweaked plotting in main()