# Can we ask ComponentMeasurements to use NonLinearModelFit to return a covariance matrix for underlying intensity data?

I'd like to be able to calculate a covariance matrix for some data underlying a morphological component. Provided this data, I can write something like:

nlm = NonlinearModelFit[data, a*3^(b*r), {a, b}, r]
nlm["CovarianceMatrix"]


To retrieve a covariance matrix given some model and a dataset. Is there some way for me to ask ComponentMeasurements to do this for me for each morphological component in some set m? What about the fitting parameters for the model?

Of course, one can go ahead and grab the intensity values for the pixels by passing "IntensityData" to ComponentMeasurements, but I'd really like to know how pass a function to ComponentMeasurements to have it do the model fitting and return the covariance matrix or fitted parameters automatically in it's typical output format. Surely there's a neat way of doing this?

-