Near- And Far- Field Optical Response Of Ensembles Of Nanostructures