A biological image analysis system for quantifying analyte staining of a biological compartment of an acquired digital image in a region in which said staining is intermixed with analyte staining of an analytically-distinct biological compartment, said system comprising a processor and memory, the memory comprising interpretable instructions which, when executed by the processor, cause the processor to perform a method comprising: executing a pattern classification function on the acquired digital image to generate a pattern map, in which the acquired digital image is segmented into a plurality of distinct regions on the basis of analyte staining pattern, the plurality of distinct regions comprising at least one compound staining region having analyte-positive staining in a first biological compartment intermixed with analyte-positive staining in at least a second biological compartment, wherein said first biological compartment and said at least a second biological compartment are analytically distinct; executing a candidate compartment segmentation function on the acquired digital image to automatically generate a candidate compartment map, identifying a candidate biological compartment comprising one or more pixel clusters in the acquired digital image that correspond to at least the first biological compartment; executing a binning function on the acquired digital image to generate an analyte intensity map, in which each pixel corresponding to the analyte is binned into one of a plurality of bins on the basis of pixel intensity; executing a true compartment identification function to identify true compartments in the compound staining regions by overlaying the pattern map, the candidate compartment map, and the analyte intensity map, wherein each pixel in a compound staining region of the at least one compound staining regions which is within both the candidate biological compartment and the bin from the analyte intensity map that is appropriate for that compartment in that compound staining region is classified as an analytically relevant pixel of the compound staining region; and automatically quantifying analyte staining in the compound staining region by calculating the mean intensity and/or average area of analytically relevant pixels. executing a pattern classification function on the acquired digital image to generate a pattern map, in which the acquired digital image is segmented into a plurality of distinct regions on the basis of analyte staining pattern, the plurality of distinct regions comprising at least one compound staining region having analyte-positive staining in a first biological compartment intermixed with analyte-positive staining in at least a second biological compartment, wherein said first biological compartment and said at least a second biological compartment are analytically distinct; executing a candidate compartment segmentation function on the acquired digital image to automatically generate a candidate compartment map, identifying a candidate biological compartment comprising one or more pixel clusters in the acquired digital image that correspond to at least the first biological compartment; executing a binning function on the acquired digital image to generate an analyte intensity map, in which each pixel corresponding to the analyte is binned into one of a plurality of bins on the basis of pixel intensity; executing a true compartment identification function to identify true compartments in the compound staining regions by overlaying the pattern map, the candidate compartment map, and the analyte intensity map, wherein each pixel in a compound staining region of the at least one compound staining regions which is within both the candidate biological compartment and the bin from the analyte intensity map that is appropriate for that compartment in that compound staining region is classified as an analytically relevant pixel of the compound staining region; and automatically quantifying analyte staining in the compound staining region by calculating the mean intensity and/or average area of analytically relevant pixels.