前提・実現したいこと
ta-lib を使いたい
ここに質問の内容を詳しく書いてください。
ta-libをインストールしたく、
ダウンロードしてから
brew install talib
pip install talib
としてもエラーが出てきて、プログラムを実行しても
no moduleとなってしまいます。
どうすれば良いでしょうか?
(例)PHP(CakePHP)で●●なシステムを作っています。
■■な機能を実装中に以下のエラーメッセージが発生しました。
発生している問題・エラーメッセージ
brew install talib
Error: No available formula with the name "talib"
==> Searching for a previously deleted formula (in the last month)...
Warning: homebrew/core is shallow clone. To get complete history run:
git -C "$(brew --repo homebrew/core)" fetch --unshallow
Error: No previously deleted formula found.
==> Searching for similarly named formulae...
This similarly named formula was found:
ta-lib ✔
To install it, run:
brew install ta-lib ✔
==> Searching taps...
==> Searching taps on GitHub...
Error: No formulae found in taps.
Siri:~ yamato$ pip install talib
Collecting talib
Downloading https://files.pythonhosted.org/packages/1a/80/3492aa3065d7d81a6c51db78920108f84fbe19c4e2740f6bbb83d42f77a4/talib-0.1.1.tar.gz
Building wheels for collected packages: talib
Building wheel for talib (setup.py) ... error
Complete output from command /anaconda3/bin/python -u -c "import setuptools, tokenize;file='/private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" bdist_wheel -d /private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-wheel-99qv6nfx --python-tag cp37:
running bdist_wheel
running build
running build_py
creating build
creating build/lib
creating build/lib/talib
copying talib/init.py -> build/lib/talib
copying talib/cli.py -> build/lib/talib
installing to build/bdist.macosx-10.7-x86_64/wheel
running install
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/setup.py", line 47, in <module>
'talib = talib.cli:cli',
File "/anaconda3/lib/python3.7/distutils/core.py", line 148, in setup
dist.run_commands()
File "/anaconda3/lib/python3.7/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/anaconda3/lib/python3.7/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/anaconda3/lib/python3.7/site-packages/wheel/bdist_wheel.py", line 238, in run
self.run_command('install')
File "/anaconda3/lib/python3.7/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/anaconda3/lib/python3.7/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/setup.py", line 20, in run
raise Exception("You probably meant to install and run ta-lib")
Exception: You probably meant to install and run ta-lib
Failed building wheel for talib
Running setup.py clean for talib
Failed to build talib
Installing collected packages: talib
Running setup.py install for talib ... error
Complete output from command /anaconda3/bin/python -u -c "import setuptools, tokenize;file='/private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-record-0l6edpbi/install-record.txt --single-version-externally-managed --compile:
running install
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/setup.py", line 47, in <module>
'talib = talib.cli:cli',
File "/anaconda3/lib/python3.7/distutils/core.py", line 148, in setup
dist.run_commands()
File "/anaconda3/lib/python3.7/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/anaconda3/lib/python3.7/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/setup.py", line 20, in run
raise Exception("You probably meant to install and run ta-lib")
Exception: You probably meant to install and run ta-lib
----------------------------------------
Command "/anaconda3/bin/python -u -c "import setuptools, tokenize;file='/private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-record-0l6edpbi/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/pip-install-7_1tf3z3/talib/
エラーメッセージ
該当のソースコード
ソースコード
試したこと
easy_install TA-Lib
ここに問題に対して試したことを記載してください。
Siri:~ yamato$ easy_install TA-Lib
Searching for TA-Lib
Reading https://pypi.org/simple/TA-Lib/
Downloading https://files.pythonhosted.org/packages/90/05/d4c6a778d7a7de0be366bc4a850b4ffaeac2abad927f95fa8ba6f355a082/TA-Lib-0.4.17.tar.gz#sha256=16ab1e33c547fe72c10c28b02f6ae342fbcc7eef6a49ba961c639a6020aba56a
Best match: TA-Lib 0.4.17
Processing TA-Lib-0.4.17.tar.gz
Writing /var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/easy_install-tb5_uyu2/TA-Lib-0.4.17/setup.cfg
Running TA-Lib-0.4.17/setup.py -q bdist_egg --dist-dir /var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/easy_install-tb5_uyu2/TA-Lib-0.4.17/egg-dist-tmp-pctb3fe2
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
error: Setup script exited with error: command 'gcc' failed with exit status 1
Siri:~ yamato$ easy_install TA-Lib
Searching for TA-Lib
Reading https://pypi.org/simple/TA-Lib/
Downloading https://files.pythonhosted.org/packages/90/05/d4c6a778d7a7de0be366bc4a850b4ffaeac2abad927f95fa8ba6f355a082/TA-Lib-0.4.17.tar.gz#sha256=16ab1e33c547fe72c10c28b02f6ae342fbcc7eef6a49ba961c639a6020aba56a
Best match: TA-Lib 0.4.17
Processing TA-Lib-0.4.17.tar.gz
Writing /var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/easy_install-kwtfxik_/TA-Lib-0.4.17/setup.cfg
Running TA-Lib-0.4.17/setup.py -q bdist_egg --dist-dir /var/folders/ff/jf7x45gs1gx4r37w9658ddv00000gn/T/easy_install-kwtfxik_/TA-Lib-0.4.17/egg-dist-tmp-9w670hny
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
error: Setup script exited with error: command 'gcc' failed with exit status 1
補足情報(FW/ツールのバージョンなど)
python 3.7.0
Mac OSX
MacBook Pro (Retina, 13-inch, Early 2015)
ここにより詳細な情報を記載してください。

回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2019/01/25 09:55
2019/01/25 09:56
2019/01/25 14:35
2019/01/25 14:53
2019/01/25 15:01
2019/01/25 15:14
2019/01/25 15:32
2019/01/25 16:54 編集
2019/01/25 16:11