Script to compute phase transfer entropy (PTE) in Matlab. This function is free software, distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY. It is designed and distributed for research purposes only. The authors accept no responsibility for its use.