what if python function returns a dataframe? really hope the plugin can support dataframe-matrix
Kudos for Kuba!! thanks for sharing.
Hello.
I am trying your example but have the following problem:
when executing
PyLoadFromFile("python.py");
Amibroker closes without any error message.
Any idea about what's happening?
Regards.
You should say what the error says!!!
Probably you just don't have file python.py in your AmiBroker directory ( AmiBroker working path ). You can pass to PyLoadFromFile
relative path (e.g "AmiPyCode.py"
) OR absolute path (e.g. "C:\\[...]\\AmiPyCode.py"
)
Thank you for your answer.
There is no error message when AB close.
python. py is passed with absolute path "C:\... \python. py"
New version of AmiPy is released!
Download link:
AmiPy 0.2.0: http://ev1.pl/amipy/AmiPy_0_2_0.zip
(64 bit only)
VirusTotal file check 100% clean
Changes:
Bug fixes:
- Error from AmiPy Python module doesnot throw exception now.
Added features:
- AFL function PyEvalFunction can return 2d numpy arrays from Python
Full Change log: http://ev1.pl/amipy/ChangeLog.md
Amazing! Being Amibroker + Python Fan Love to Explore AmiPy
@Kuba : Upgraded my python to 3.8 version and Using Amibroker 6.35 Version (64-bit). However Dll is not detected while opening Amibroker in Administration mode.
Am I missing anything?
First you don't need to (and should not) run AmiBroker in administrator mode. Secondly, did you install 64-bit version of Python and NUMPY?
Installed Python is 64bit. and Yes Numpy comes with preinstalled
Could you type python38.dll
in windows cmd (not Anaconda prompt)
You may need to add Python directories to Windows PATH. Otherwise system won't be able to find python DLLs. https://geek-university.com/uncategorized/add-python-to-the-windows-path/
Ordinary plain Python setup (not anaconda) adds Python directories to PATH by default, but different setups may not do that and/or you may have turned off that function.
@Kuba and @Tomasz
I installed the standalone python as well with appropriate environment variables. However unable to get the output when typed python38.dll. rest all seems to be fine to me.
Your Windows may be outdated .You may need to install latest C++ runtime from Microsoft AND/OR apply all updates to Windows.
https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads
I had installed the latest C++ runtime and windows are up to date still weird behavior that plugin is not detected
AmiPy uses python38.dll and if it's not present AmiPy won't load. When installing python normally python38.dll is in the same dir as python.exe (I don't know where it is in Anaconda release). Make sure you have python38.dll in PATH.
Thanks Kuba my issue with python installation got resolved. Initially installed python from the Microsoft windows store which doesn't had python38.dll. so removed and installed python from the https://www.python.org/downloads/windows/ with environmental variables
You must install original 64-bit PYTHON and plain vanilla one, not any other, not from Windows store, not 32-bit, not some other esoteric package from who-knows-where.
Python 3.8.5 plain vanilla Windows x64 executable installer OS: Windows, AMD64/EM64T/x64 MD5 Sum 0ba2e9ca29b719da6e0b81f7f33f08f6
File size: 27864320
New version of AmiPy is released!
Download link:
AmiPy 0.3.0: http://ev1.pl/amipy/AmiPy_0_3_0.zip
(64 bit only)
VirusTotal file check 100% clean
Changes:
Added features:
- Added multi interpreter support (All functions take additional parameter - interpreter name)
Full Change log: http://ev1.pl/amipy/ChangeLog.md
Documentation: http://ev1.pl/amipy/README.md