Re: [MORPHMET] A question about geometric morphometrics

2019-04-15 Thread Joseph Kunkel
With reference to the Yang Chang skull group query:

I am a devotee of Analysis of Dispersion combined with Factorial Design of CR 
Rao (1965).

The model is  Y = XB

Y is a n by 3k+c matrix of n rows of k xyz coordinates plus c covariates such 
as size and weight covariates.

X is a n by p design matrix of assignment multipliers to chose the B matrix 
factor values. 

-the elements of X are usually 1s, 0s and -1s.

B is a matrix of p by 3k+c factors which are tested for their significance as 
factors.

As usual the solution is B = (X’X)^-1(X’Y).

3k columns of Y are the matrix of landmarks rotated and resized by the usual 
landmark alignment process. And one of the c columns of the Y matrix is the 
resizing size value produced in the alignment.

I use the Analysis of Dispersion (Rao 1965) to test the significance and obtain 
the crossproducts matrices that reduces the total sums of squares and 
crossproducts matrix Y’Y for the mean and independent factors, in your case the 
groups of skulls.

The residual covariance matrix is used to test for the significance of the 
factors which at this point are not corrected for the covariance with size (for 
instance).

Next, within Rao's Analysis of Dispersion one tests the factor crossproducts 
matrices of the Y columns for whether there is any additional information in 
one or more of the covariates (such as the size column).  If there is no 
additional info in the size covariate one can ignore it.  If one or more 
covariates is significant one can change the Equation to be:

Y’ = ZB = [Yc | Yd | X]B

Y' is the Y matrix with the covariate columns removed.

Yc and Yd are the significant covariate columns appended to the design matrix X 
to create Z extended design.

That system of matrix equations is solved the same way as previously but since 
c and d covariates are likely not independent of the factor design columns 
their sums of squares and crossproducts reduction are calculated by subtraction 
rather than being independently calculable.

This is all quite simple if one is familiar with factorial design, just 
generalized to a n by 3k Y matrix of observations.

It is explained in matrix algebra by Rao (1965).

I have implemented it in R if you have the patience of following the rules of 
design matrices and choosing factors to be tested independently or by 
subtraction.

I am not sure Jim would approve of this specific approach but I am convinced 
that it is correct and gives you a test of significance as well as a way of 
calculating the expected Y', Yhat.

Yhat = ZB

Which provides with the factors which allows computation of average differences 
between factor groups and with chosen c and d covariate effects.

CR Rao (1965) Linear Statistical Inference and Its Applications.John Wiley & 
Sons, New York, 522pp.
I have recently upgraded my R scripts to be consistent with recent versions of 
R. The two relevant R-scripts are Andy.R and ad info.R

http://www.bio.umass.edu/biology/kunkel/pub/r_scripts/andy/ 


The sample inputs found there are csv matrices that a simple YX matrices of 
appended Y and design matrix X.

If you need help with their use I am available by Email.

Joe
-·.  .· ·.  .><º>·.  .· ·.  .><º>·.  .· ·.  .><º> .··.· >=-   
=º}><
Joseph G. Kunkel, Research Professor
122C/125 Pickus Center for Biomedical Research
Marine Science
University of New England
Biddeford ME 04005
http://www.bio.umass.edu/biology/kunkel/ 



> On Apr 11, 2019, at 5:31 AM, yang Chang  wrote:
> 
> I want to compare skull morphology using geometric morphometrics from several 
> species with different diets in a same genus. But I don't know much about how 
> to analyze these shape data. What statistical analysis can I do? I know that 
> principal component analysis can be done to visualize shape variations. So 
> can I use the original coordinate data? Do I need to remove the effects of 
> size and phylogenetic relationships to do principal component analysis? If 
> so, do I use PGLS to do the regression of shape and size, and then use the 
> obtained residual as the principal component analysis? In addition to this 
> analysis, what other aspects can I do? Looking forward to reply.Thanks very 
> much!
> 
> -- 
> MORPHMET may be accessed via its webpage at http://www.morphometrics.org
> --- 
> You received this message because you are subscribed to the Google Groups 
> "MORPHMET" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to morphmet+unsubscr...@morphometrics.org.

-- 
MORPHMET may be accessed via its webpage at http://www.morphometrics.org
--- 
You received this message because you are subscribed to the Google Groups 
"MORPHMET" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to morphmet+unsubscr...@morphometrics.org.


Re: [MORPHMET] micro-CT suggestions

2016-12-06 Thread Joseph Kunkel
Angela,

We are studying lobster cuticle with the SkyScan 1272 (which has a carousel 
sampler that holds 18 samples).  My regular sized object is a 6mm medallion of 
cuticle which can be scanned entirely at at 2.5 um resolution.  Smaller regions 
of interest can be analyzed but the size of the computational boundary must be 
smaller.  We recently published a MS on cuticle structures available at URL:  
http://www.bio.umass.edu/biology/kunkel/pub/reprints/FISH_4564_20161020JGKarch.pdf

We provide a Supplementar Table that lists the size of the scan and achievable 
resolution at that size.

The 1172 and 1174 both have a 6um resolution ‘limit’ perhaps associated with 
scanning larger structures.

I am not sure what the differentiates the 72 vs 74.   

-·.  .· ·.  .><º>·.  .· ·.  .><º>·.  .· ·.  .><º> .··.· >=-   
=º}><
Joseph G. Kunkel, Research Professor
112A Marine Science Center
University of New England
Biddeford ME 04005
http://www.bio.umass.edu/biology/kunkel/

> On Dec 6, 2016, at 3:10 AM, Angela Roggero  wrote:
> 
> dear Luci,
> we too are interested in buying a microCT, and are examining some instruments 
> just now. Essentially, we want to scan hundreds of similar, small and 
> low-density objects (insects), and recently tested both SkyScan 1174, and 
> 1172 (Brucker). Besides, I will be glad to know what is the better choice of 
> microCT to be used on insects. Many thanks for any information, Angela Roggero
> 
> Il 06/12/2016 01.06, Murat Maga ha scritto:
>> Dear Luci,
>>  
>> The very short answer is, it depends on your application (scanning hundreds 
>> of same thing or a multi-user facility in which users will want to scan 
>> rocks, biological specimens, engine parts). The major companies I am 
>> familiar with are Bruker (Skyscan), Scanco and GE. Expect to pay anywhere 
>> from $250K to $700K, depending on the scanner you choose and your support 
>> agreement.
>>  
>> Whatever you choose, there are very good open source packages. If you are 
>> spending tens of thousands of dollars on your analysis and visualization 
>> software, you are wasting money.
>>  
>> M
>>  
>>  
>> From: Kohn, Luci [mailto:lk...@siue.edu] 
>> Sent: Wednesday, November 30, 2016 6:41 AM
>> To: MORPHMET 
>> Subject: [MORPHMET] micro-CT suggestions
>>  
>> I am planning to apply for funding for a micro-CT unit (and associated 
>> software.  Does anyone have suggestions of models they would recommend?
>>  
>> Thanks in advance
>> Luci Kohn
>>  
>>  
>> Luci Kohn, Ph.D.
>> Associate Professor
>> Department of Biological Sciences, Box 1651
>> 44 Circle Drive, SLW 1155
>> Southern Illinois University Edwardsville
>> Edwardsville, IL  62026-1651
>> Phone:  (618) 650-2394
>> Fax:  (618) 650-3174
>> e-mail:  lk...@siue.edu
>>  
>>  
>>  
>> -- 
>> MORPHMET may be accessed via its webpage at http://www.morphometrics.org
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "MORPHMET" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email tomorphmet+unsubscr...@morphometrics.org.
>> -- 
>> MORPHMET may be accessed via its webpage at http://www.morphometrics.org
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "MORPHMET" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to morphmet+unsubscr...@morphometrics.org.
> 
> -- 
> Dott. Angela Roggero
> Dpt. Scienze della Vita e Biologia dei Sistemi
> Via Accademia Albertina 13
> I-10123 Torino - ITALY 
> Phone +39 011 670 4536
> Fax +39 011 236 4536
> 
> -- 
> MORPHMET may be accessed via its webpage at http://www.morphometrics.org
> --- 
> You received this message because you are subscribed to the Google Groups 
> "MORPHMET" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to morphmet+unsubscr...@morphometrics.org.

-- 
MORPHMET may be accessed via its webpage at http://www.morphometrics.org
--- 
You received this message because you are subscribed to the Google Groups 
"MORPHMET" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to morphmet+unsubscr...@morphometrics.org.



Re: [MORPHMET] geomorph update

2016-03-03 Thread Joseph Kunkel
Aha, the non-symmetrical quotes effect.   I have seen it before.  

-·.  .· ·.  .><º>·.  .· ·.  .><º>·.  .· ·.  .><º> .··.· >=-   
=º}><
Joseph G. Kunkel, Research Professor
112A Marine Science Center
University of New England
Biddeford ME 04005
http://www.bio.umass.edu/biology/kunkel/

> On Mar 3, 2016, at 9:00 AM, Collyer, Michael  wrote:
> 
> Colleagues,
> 
> We have made a small update to the procD.allometry function to fix a bug with 
> centering shape data to calculate CAC scores.  Thanks to Borja Figueirido for 
> discovering the problem!
> 
> As always, updates to geomorph are made available via our GitHub repository, 
> and the latest version of geomorph can be installed with one line of code in 
> R:
> 
> devtools:::install_github(“geomorphR/geomorph”, ref = “Stable")
> 
> Cheers!
> Mike
> 
> Michael Collyer
> 
> Associate Professor
> Biostatistics
> Department of Biology
> Western Kentucky University
> 1906 College Heights Blvd. #11080 
> Bowling Green, KY 42101-1080
> Phone: 270-745-8765; Fax: 270-745-6856
> Email: michael.coll...@wku.edu
> 
> 
> -- 
> MORPHMET may be accessed via its webpage at http://www.morphometrics.org
> --- 
> You received this message because you are subscribed to the Google Groups 
> "MORPHMET" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to morphmet+unsubscr...@morphometrics.org.

-- 
MORPHMET may be accessed via its webpage at http://www.morphometrics.org
--- 
You received this message because you are subscribed to the Google Groups 
"MORPHMET" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to morphmet+unsubscr...@morphometrics.org.



Re: [MORPHMET] Mahalanobis distance in cluster analysis of shape variables

2016-01-30 Thread Joseph Kunkel
I can not speak directly to why it is frequently used in GM cluster analysis 
but I would like to mention how I look at Mahalanobis distance based on its 
calculation.

Mahalanobis distance is not a pure distance metric like Euclidian or Manhattan 
distance, as you have stated it is ‘standardized’.  What doe that really mean?  
It sounds supeficially good.

One way of computing it is to rotate the k-landmark data set to simplest form 
treating the landmarks as factors.  This way would consider all landmarks to 
have a common covariance structure in XY or XYZ in three dimensions.  That is a 
already a streetch, since not all landmarks can be assumed to have the same 
covariance structure.  In addition the landmarks have all been already centered 
about their centroid and rotated to coincide, which has eliminated a dgeree of 
freedom of variability that can have consequences.  

Furthermore not all species landmarks can be expected to have the same 
covariance structure, which is an assumption made in the ordinary Mahalanobis 
distance application to strut analysis between populations or species.  The 
assumption of similar data structure of course applies to the null hypothesis 
where there is no difference.  The typical statistical test explodes when the 
null hypothesis is falsified so just when you want the Mahalanobis distance 
metric to be accurate it starts misbehaving.

After rotation to simplest axes one does an 1 df F-test between each of the 
landmarks.  These tests are all independent so they can be summed together to 
produce a k df F-test which is Mahalonobis D squared.So Mahalonobis D is 
the square root of the sum of independent F-tests, but those F-tests are based 
on all sorts of assumptions about the variance of the landmarks.  I immagine on 
could modify calculation of D by limiting the sum over the top 95 or 99% 
variance components of the principal components.

Many times applications of analytical techniques are judged by whether they 
‘work’ or not.   If a clustering method works for you, use it(?).  I am of the 
opinion that I use statistics to convince myself rather than the audience.   A 
confluence on many arguments is used to make a case.

Joe

-·.  .· ·.  .><º>·.  .· ·.  .><º>·.  .· ·.  .><º> .··.· >=-   
=º}><
Joseph G. Kunkel, Research Professor
UNE Biddeford ME 04005
http://www.bio.umass.edu/biology/kunkel/

> On Jan 30, 2016, at 7:11 AM, Elahep  wrote:
> 
> 
> Hello all,
> 
> 
> 
> I have seen in many GM articles people use Mahalanobis distance for cluster 
> analysis. What is the advantage of using Mahalanobis distance over Euclidian 
> distance as similarity measure in cluster analysis of shape variables?
> 
> As far as I know Mahalanobis distance is the standardized form of Euclidean 
> distance which standardized data with adjustments made for correlation 
> between variables and weights all variables equally.
> 
> Why this distance measure is frequently used in GM cluster analysis??
> 
> 
> 
> Thanks in advance
> 
> Elahe
> 
> 
> -- 
> MORPHMET may be accessed via its webpage at http://www.morphometrics.org
> --- 
> You received this message because you are subscribed to the Google Groups 
> "MORPHMET" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to morphmet+unsubscr...@morphometrics.org.

-- 
MORPHMET may be accessed via its webpage at http://www.morphometrics.org
--- 
You received this message because you are subscribed to the Google Groups 
"MORPHMET" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to morphmet+unsubscr...@morphometrics.org.



[MORPHMET] tpsDig on a Mac using wine

2015-05-23 Thread Joseph Kunkel
Dear Jim and Morphmet,

I just want to comment on using tpsDig on a Mac.  tps Dig is my go-to software 
for 2-D landmark digitizing of images.  To digitize I would previously have to 
use one of my PCs in my lab which was often a pain.  I was reluctant to use 
several of the PC-on-your-Mac options because they meant partitioning your disc 
or in some sense running two separate worlds on your Mac which always made me 
nervous for several security software reasons.  
Using the emulation program, wine (https://www.winehq.org/ 
https://www.winehq.org/), has changed everything.  It works as a unix program 
run from your Mac Terminal console.  I have tested several of the tps suite of 
software from Rohlf and they work like a charm.  One trick however to get 
around the need for a ‘right-click’ in tpsDig is to redefine the right-click as 
something else such as a track-pad tap which works like a charm.
Thank you wine for allowing me to ‘go home’ and do tpsDig on my Macs!

-·.  .· ·.  .º·.  .· ·.  .º·.  .· ·.  .º .··.· =-   
=º}
Joseph G. Kunkel, Emeritus Professor
Biology Department
UMass Amherst 
Amherst MA 01003
j...@bio.umass.edu



-- 
MORPHMET may be accessed via its webpage at http://www.morphometrics.org

To unsubscribe from this group and stop receiving emails from it, send an email 
to morphmet+unsubscr...@morphometrics.org.


[MORPHMET] Use of tpsDig2 template mode on dragonfly wings

2014-11-12 Thread Joseph Kunkel
Dear tpsDig users,

After a time away from using tpsDig I am back digitizing Sympetrum (Medowhawk 
dragonfly) wings with tpsDig2 … with a twist.  I am doing it on a Mac using 
wine, the PC emulator.  It works well but I am in need of one of the old 
functions called template-mode.

In the 'old days', template mode allowed you to use an empty tps list of image 
file names with LM set to zero to acquire a first set of landmarks on specimen 
1 and then inherit those landmarks to specimen 2 and then in an edit step take 
one of the extreme landmarks and move it to its correct location on specimen 2 
with all the other landmarks following in parallel.  Then on had the 
opportunity to pick up another extreme landmark and move it to its correct 
location … all the while the other landmarks were scaled to fall at their 
calculated positions in between … relatively close to where they should be in a 
similar or identical species.  This was a very valuable tool for inheriting the 
general locations of landmarks on 2-D specimens such as my hundreds of 
Sympetrum wings.

Now, as I am using the template mode of tpsDig2 most recent version, I see that 
the new inheritance mode works differently and I want to be sure that I can use 
it most effectively.

I now, after digitizing my first specimen in the tps list, put on template mode 
and go to my next image.  I then grab a central, rather than an extreme 
landmark and move it to its correct location on the image. Once I then release 
it all the other inherited landmarks have been moved in parallel to new 
locations somewhat near their correct locations but would benefit from rotation 
or isometric scaling to be closer to their correct locations on the image.  I 
then have the sometimes laborious task of moving the landmarks to their correct 
positions and when they need substantial rotation or resizing the task is more 
laborious than in the old days when the resizing and rotation were a part of 
the inheritance protocol.   …   Am I missing some widget or control-key the 
would allow better inheritance of the landmark positions.  Perhaps in using 
wine I have lost some help file  that would have told me how to use the new 
inheritance tool.

It still is the best 2-D digitizing software, is it not?

Joe

-·.  .· ·.  .º·.  .· ·.  .º·.  .· ·.  .º .··.· =-   
=º}
Joseph G. Kunkel, Emeritus Professor
Biology Department
UMass Amherst
Amherst MA 01003
j...@bio.umass.edu



This e-mail may contain information that is privileged and confidential. If you 
suspect that you were not intended to receive it please delete it and notify 
the sender as soon as possible.

-- 
MORPHMET may be accessed via its webpage at http://www.morphometrics.org

To unsubscribe from this group and stop receiving emails from it, send an email 
to morphmet+unsubscr...@morphometrics.org.