[Phylobase-commits] r785 - in pkg: inst/nexusfiles src

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Apr 12 20:56:01 CEST 2010


Author: francois
Date: 2010-04-12 20:56:01 +0200 (Mon, 12 Apr 2010)
New Revision: 785

Modified:
   pkg/inst/nexusfiles/ExContData.Rdata
   pkg/src/NCLInterface.cpp
Log:
fix rounding difference in nexus files between windows and unix by increasing precision to 10 decimals (code by Mark Holder), change representation for test accordingly

Modified: pkg/inst/nexusfiles/ExContData.Rdata
===================================================================
(Binary files differ)

Modified: pkg/src/NCLInterface.cpp
===================================================================
--- pkg/src/NCLInterface.cpp	2010-04-12 18:53:49 UTC (rev 784)
+++ pkg/src/NCLInterface.cpp	2010-04-12 18:56:01 UTC (rev 785)
@@ -377,7 +377,10 @@
 							nexuscharacters+="NA";
 					}
 					else {
-						nexuscharacters+=state;
+					    //nexuscharacters+=state;
+					    char buffer[100];
+					    sprintf(buffer, "%.10f", state);
+					    nexuscharacters+=buffer; 
 					}
 
 					if (taxon+1<ntax) {



More information about the Phylobase-commits mailing list