issues running jmp2pandas.pyI am getting a termination error every time I run jmp2pandas. The table is formed, but then the termination error appears (see attached image).
import jmp2pandas
import pandas as pd
data = {
"Name": ["Alice", "Bob", "Charlie"],
"Age": [25, 30, 35],
"City": ["New York", "London", "Paris"]
}
df = pd.DataFrame(data)
jmp2pandas.df2dt(df,dt_title='Example df to dt')Automation and ScriptingRe: issues running jmp2pandas.pyAI in the loop?
Re: issues running jmp2pandas.pyWhich JMP version are you using?
Re: issues running jmp2pandas.pyJMP 19.0.0
Re: issues running jmp2pandas.pyAre you asking if AI is being used? or if AI is causing the error?
Re: issues running jmp2pandas.pyI would suggest using more modern methods to go from dataframe to datatable as you have JMP19 (jmp.from_dataframe)
View more...
import jmp
import jmputils
try:
# pandas depends on numpy will install numpy if needed
if not jmputils.is_installed('pandas'):
jmputils.jpip('install', 'pandas', echo=False)
except Exception as e:
print(f'Install failed with exception: {e}')
import pandas as pd
import numpy as np
pandas_df = pd.DataFrame(
{
"A": 1.0,
"B": pd.Timestamp("20130102"),
"C": pd.Series(1, index=list(range(4)), dtype="float32"),
"D": np.array([3] * 4, dtype="int32"),
"E": pd.Categorical(["test", "train", "test", "train"]),
"F": "foo",
}
)
print(pandas_df)
dt = jmp.from_dataframe(pandas_df)
print(dt)
See Scripting Index
Going further with Python in JMP 19
Re: issues running jmp2pandas.pyAgreed!
I guess @mhw_novonesis was using this reference: Creating a Pandas DataFrame from a JMP Data Table, but now there is the new function (as of JMP 19): jmp.from_dataframe()