5. Open-Bio BOF 2004 at GIW2004Open-Bio BOF 2004 at GIW2004
バイオインフォマティクスとバイオインフォマティクスと Python (3/3)Python (3/3)
データの解析や表示データの解析や表示
– CC ライブラリでの数値計算ライブラリでの数値計算
(Numeric/numarray)(Numeric/numarray)
– 画像処理/グラフ化画像処理/グラフ化 (PIL,(PIL,
matplotlib etc)matplotlib etc)
– クロスプラットフォームなクロスプラットフォームな
GUIGUI アプリケーションのアプリケーションの
開発開発
(Tkinter, PyQt, wxPython,(Tkinter, PyQt, wxPython,
etc.)etc.)Spherical Som visualization (Python+
wxPython+VTK, not published)
BL-SOM visualization (Python +Tk+
DDBJ ClastalX, not published)
6. Open-Bio BOF 2004 at GIW2004Open-Bio BOF 2004 at GIW2004
BioPythonBioPython プロジェクトプロジェクト
Jeffrey Chang, Andrew DalkeJeffrey Chang, Andrew Dalke
(Aug 1999)(Aug 1999)
The Biopython ProjectThe Biopython Project
(http://www.biopython.org/) is a(http://www.biopython.org/) is a
new open collaborative effort tonew open collaborative effort to
developdevelop freely available Python
libraries and applicationsand applications thatthat
address the needs of currentaddress the needs of current
and future work inand future work in
bioinformatics, includingbioinformatics, including
sequence analysissequence analysis,, structuralstructural
biologybiology,, pathwayspathways,, expressionexpression
datadata, etc., etc.
Biopython project
http://www.biopython.org/
12. Open-Bio BOF 2004 at GIW2004Open-Bio BOF 2004 at GIW2004
例題例題 (1/2)(1/2)
from Bio.WWW import NCBI
# NCBI にクエリを出す
res = NCBI.query('Search', 'PubMed', term='BioPython',doptcmdl='Summary')
# 結果を読み出してファイルに保存
of = open('outfile.html', 'wb')
of.write(res.read())
of.close()
# ブラウザで表示
import webbrowser
webbrowser.open('outfile.html')
13. Open-Bio BOF 2004 at GIW2004Open-Bio BOF 2004 at GIW2004
例題例題 (2/2)(2/2)
['15336256', '15221224', '15210717', '15186836', '15161048', '15141082', '15133320', '15133034',
...
'6263546', '7426031', '6774736', '229857', '4992780', '5273780']
['Saito A', 'Doi Y', 'Tanaka A', 'Matsuura N', 'Ubukata M', 'Nakajima N'] Systematic synthesis of four
epicatechin series procyanidin trimers and
their inhibitory activity on the Maillard reaction and antioxidant
activity. Bioorg Med Chem 2004 Sep 15;12(18):4783-90.
['Ihara N', 'Kurisawa M', 'Chung JE', 'Uyama H', 'Kobayashi S'] Enzymatic synthesis of a catechin
conjugate of polyhedral oligomeric
...
from Bio.PubMed import Dictionary, search_for
# カテキン合成を PubMed でサーチ
entries = search_for('catechin synthesis')
print entries
from Bio.Medline import RecordParser
# Medline エントリのパーザを作成
recparser = RecordParser()
# 最初の 10 件について, 3 秒ごとにクエリを出し,サーチ結果をパーザで解析して,
# 著者,タイトル,出典を表示
rdict = Dictionary(delay=3.0, parser=recparser)
for e in entries[:10]:
record = rdict[e]
print record.authors, record.title, record.source
14. Open-Bio BOF 2004 at GIW2004Open-Bio BOF 2004 at GIW2004
Acknowledgements and CopyrightsAcknowledgements and Copyrights
資料中に使われているクリップアートワークは,資料中に使われているクリップアートワークは, MicrosoftMicrosoft
OfficeOnlineOfficeOnline クリップアートコレクションをもとに作成しました.クリップアートコレクションをもとに作成しました.
使用条件については使用条件については http://office.microsoft.com/clipart/http://office.microsoft.com/clipart/ をご覧くださいをご覧ください
..
その他クリップアートを使わない図形や写真,および本文テキストその他クリップアートを使わない図形や写真,および本文テキスト
の著作権は増田泰の著作権は増田泰 (ymasuda at ethercube.com)(ymasuda at ethercube.com) に帰属し,以下のに帰属し,以下の
条件で再配布および改変を認めます.条件で再配布および改変を認めます.Copyright Notice
Copyright Yasushi Masuda, 2004 All Rights Reserved
Permission to use, copy, modify, and distribute this product for any purpose and without fee is hereby granted, provided that above
copyright notice and this permission notice is attached with every copies or distributions.
Disclaimer
Yasushi Masuda (the author hereafter) disclaims all warranties with regard to this product, including all implied warranties of merchantability
and fitness, in no event the author shall be liable for any special, indirect or consequential damages or any damages whatsoever resulting
from loss of use, data or profits, whatever in an action pf contract, negligence or other tortious action, arising out of or in connection with the
use or derivation of this product.
The author makes any warranty, express or implied, or assumes any liability or responsibility for the accuracy, completeness, or usefulness
of any information, apparatus, product, or process disclosed, or represents that its use would not infringe privately-owned rights.
Reference herein to any specific commercial products, process, or service by trade name, trademark, manufacturer, or otherwise, does not
necessarily constitute or imply its endorsement, recommendation, or favoring by the author. The views and opinions of authors expressed
herein do not necessarily state or reflect those of the author, and shall not be used for advertising or product endorsement purposes.
PDF 版は http://www.cubelab.com/ymasuda/python/misc/ で入手できます