Date Column from R Data Function to Spotfire

I am trying to return a table from a data function that contains a Date column. The function works if I cast the date colunm to a string. I have tried many different types of Date format and all return the following error


Could not execute function call.
TIBCO Spotfire Statistics Services returned an error: 'marshallSpotfireOutputParameters(outputs, envir = envir) : error writing output variable "DailyForecastData" to file "D:/Program Files/TIBCO/statsvcs50/SplusServer/data/artifacts/spotfire/b99099b2-0674-41c2-ba00-124114270293.sbdf" : Error in exportDataToSBDF(data, file = file) :
  Error occurred while exporting to D:/Program Files/TIBCO/statsvcs50/SplusServer/data/artifacts/spotfire/b99099b2-0674-41c2-ba00-124114270293.sbdf: input data has different number of columns than the number of input column types'.
   at Spotfire.Dxp.Data.DataFunctions.Executors.RemoteFunctionClient.OnExecuting(FunctionClient funcClient)
   at Spotfire.Dxp.Data.DataFunctions.Executors.AbstractFunctionClient.<RunFunction>d__3.MoveNext()
   at Spotfire.Dxp.Data.DataFunctions.Executors.SPlusFunctionExecutor.<ExecuteFunction>d__3.MoveNext()
   at Spotfire.Dxp.Data.DataFunctions.DataFunctionExecutorService.<ExecuteFunction>d__6.MoveNext()"

What do I need to do to have the table return with a date column?

(2) Answers