# Is there a way to calculate the Ka/Ks value in R/unix?

I am investigating the rate of synonymous non synonymous substitutions and would like to find the Ka/Ks value also known as dn and ds between multiple alleles? I want to investigate multiple alleles because I am examining the MHC region which is highly polymorphic. Any suggestions would be very helpful!

A while back, I used PAML for this purpose for a phylogenetics project. It has Windows and macOS executables but for *nix, you will need to compile it from source code.