 
 # CDF of t distribution
 pt = (x, df) ->
+    x = parseFloat(x)
+    df = parseFloat(df)
     if df <= 0
         console.log("dt: df must be positive")
         return null


# quantile of t distribution by binary search
qt = (p, df, hi=5, tol=0.0001) ->
    if df <= 0
        console.log("qt: df must be positive")
        return null


# t density
dt = (x, df) ->
    x = parseFloat(x)
    df = parseFloat(df)
    if df <= 0
        console.log("dt: df must be positive")
        return null
