ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

[­ì³Ð] python¤W¥«Âd¤T¤jªk¤H¶R½æ¶W¤é³ø¸ê®Æ¤U¸ü

¦^´_ 160# zyzzyva
¥Ø«e§Ú¤w¦w¸Ë¤F Anaconda2-4.0.0-Windows-x86_64¡A
¥¿¦b´ú¸Õ¤¤¡A¬Ý°_¨Ó¦n¹³ÆZ¥¿±`ªº (Available Kernels )¡C¦pªG¤@¤Á OK¡A
¦^ÀY±N¥¦²¾°£¦A¦w¸Ë Anaconda3-4.2.0-Windows-x86_64 ´ú¸Õ¬Ý¡C

TOP

¦^´_ 160# zyzzyva
¦p¹Ï¥Ü¡G

TOP

¦^´_ 162# c_c_lai
¦³¸Õ¹L°õ¦æjupyter notebook --debug¶Ü¡H¦³¨S¦³¤ñ¸û¸Ô²Óªº¸ê°T¡H

TOP

¦^´_ 163# zyzzyva
¦UºØª¬ªp§Ú³£¤@¤@´ú¸Õ¹L¡A³Ì«á¤S¦^¨ì
¦w¸Ë Anaconda2-4.0.0-Windows-x86_64 ª©¥»¡A
¯u¤£ª¾¯u¥¿­ì¦]¦b­þ¸Ì (ºô¸ô¤W¬Û¦P´£°Ý§¡µL¸Ñ)¡C

TOP

¦^´_ 163# zyzzyva
1.) Anaconda3-4.2.0-Windows-x86_64.exe
2.) Anaconda3-4.1.1-Windows-x86_64.exe
¥u­n¦w¸Ë¥H¤W¨âºØ ¤§¥ô¤@¶µ¡A¦b°õ¦æ jupyter notebook
«á¡AÀH·N¶}±Ò *.ipynb ªºÀɮ׮ɡA§¡·|¥X²{ "No Kernels" ªºµ²ªG¡C
§A¥i¸ÕµÛ ¦w¸Ë¥H¤W¥ô¤@¤§ *.exe ¬Ý¬Ý¬O§_¯à¶¶§Q°õ¦æ¡H

TOP

¥»©«³Ì«á¥Ñ c_c_lai ©ó 2016-10-14 11:39 ½s¿è

¦^´_ 163# zyzzyva
±o¨ì¤@­Óµ²½×¡G
µL½×¦w¸Ë¥ô¦óª©¥»¡A³z¹L Anaconda Navigator ¥h°õ¦æ spider ©Î jupyter notebook
µ¥¡A¦p¥X²{ "The kernel appears to have died.  It will restart automatically" µ¥ª¬ªp®É¡A
¸Ñ¨M¤§¹D¬O¡G

¤£­n¦A³z¹L Anaconda Navigator ¥h°õ¦æ¡A ª½±µ¦Ü \Anaconda3\Scripts ¸Ì±N
jupyter-notebook.exe «ü¦V¤@­Ó±¶®|¡AµM«á¨C¦¸§¡¥Ñ¦¹±¶®|°õ¦æ¡C
¸g´ú¸Õ¹L¦h­Óª©¥»ÁÙÆZºÞ¥Î (ÆF¥ú) ªº¡A¦p¦¹«K¦AµL "No Kernels" ªº§xÂZ¤F¡C
§Ú­Ó¤H§PÂ_À³¸Ó¬O Navigator  ¥h³sµ²¥¦¥»¨­ªº¤l¿ï¶µ®É¡A¦bÀô¹Ò³]©w¤¤¥X¤F°ÝÃD¡C

TOP

¦^´_ 166# c_c_lai
§Ú¦³¥Î¥t¤@¥xwin7¹q¸£Äé Anaconda3-4.2.0-Windows-x86_64.exe¡A°õ¦æ°_¨Ó³£¥¿±`¡C
¤£¹L¯à¶¶§Q¸Ñ¨M¯u¬O¤Ó¦n¤F¡A³oºØÀô¹Ò³]©wªº°ÝÃDÅܼƫܦh¡A¦³®É­Ô§ä¤£¥X½T¤Áªº­ì¦]¡A¯uªº¦³ÂI·Ð¤H¡C

TOP

¥»©«³Ì«á¥Ñ c_c_lai ©ó 2016-10-15 07:52 ½s¿è

¦^´_ 167# zyzzyva
¥Ø«e§Ú¤£«H¨¸¡A¤S±N Anaconda3-4.2.0-Windows-x86_64.exe ¦w¸Ë¨ì C ¼Ñ¡A
¨Ï¥Î¤è¦¡·Ó #166 ©Ò­z°õ¦æ¡A¤j³¡¤Àªº *.ipynb §¡¯à¶¶§Q°õ¦æ¡A
«e°}¤l (¤@¶g«e) ¬O¯à¥¿±`§@·~¡F¸g§A³o»ò¤@´£¥Ü¡A¹îı·¥¦³¥i¯à¬O OS ªº¦Û°Ê½u¤W§ó·s
¦³Ãö¡C´X¦~«e¥çµo¥Í¹L¦¹Ãþ¦ü±¡ªp¡G§Y Excel »P¨é°Óªº DDE ³s½u¡A¦³¤Ñ¦b¸g¹L·L³n§@·~¨t²Î
§ó·s Service Pack «á§Y«Å§iµLªk§ä¨ì³s¤W DDE ªº®M¥ó¡F¸gÆ[¹î¨ºªñ¤é°ÊºA¡A¶È¦³ Service Pack
³Q§ó·s¡A©ó¬O¤â°Ê±N¨ä·í¤é§ó·sªº¤¸¥ó¤@¤@ÁÙ­ì¡A¦b­«·s¶}¾÷«áÀH§Y¥¿±`§@·~¡C
·í®É¥»½×¾Â (»P¨ä¥L½×¾Â) ¥ç¦³¼Æ¦ì¥ý¶i¥ç´¿µo¥Í¡A§Ú±N¸Ñ¨M¤è¦¡§iª¾¤j®a¤@¥­¦wµL¨Æ¡C
¥Ø«e¬O¨Ï¥Î Windows 10 (­ì¥»¬° Window 7¡A¸g·L³n§K¶O½u¤W¦Û°Ê¤É¯Å¦Ü Window 10)¡C

TOP

import pandas as pd
import requests
import html5lib
from bs4 import BeautifulSoup
payload={
'encodeURIComponent':'1',
'step':'1',
'firstin':'1',
'off':'1',
'keyword4':'',
'code1':'',
'TYPEK2':'',
'checkbtn':'',
'queryName':'co_id',
'inpuType':'co_id',
'TYPEK':'all',
'isnew':'false',
'co_id':'1101',
'year':'105',
'month':'11'  
}
res= requests.post('hXXp://mops.twse.com.tw/mops/web/ajax_t05st10_ifrs',data=payload)
res.encoding='utf-8'
soup=BeautifulSoup(res, "lxml")
s=pd.read_html(soup)


½Ð°Ý§Ú¼g³o¼ËpandasŪ¤£¨ìtable
Åã¥Üno table  
¸Ó¦p¦ó­×§ï?

TOP

¦b¶×¤Jºô­¶®É¡A±`±`·|¹J¨ìµLªk¶×¤Jªºª¬ªp¡A½Ð°Ý¸Ó¦p¦ó¸Ñ¨M©O?
¬O§_¦³¬ÛÃöªº¤å³¹¥i¨Ñ°Ñ¦Ò?

EX¡Gmini S&P ¿ï¾ÜÅvªº¦U¼i¬ù»ù¥æ©ö¼Æ¾Ú(¦bCMEºô¯¸)
§Ú·Q­n³z¹LVBA¤U¸ü«o¤@ª½¥¢±Ñ...

¦]¬°§ÚµLªkµo¥¬ºô§}(³Q¨t²Î¾×±¼)¡A©Ò¥H¥u¯à¥Î¶K¤W¹Ï¤ù

[attach]27980[/attach]

TOP

        ÀR«ä¦Û¦b : ¤Ñ¤W³Ì¬ü¬O¬P¬P¡A¤H¥Í³Ì¬ü¬O·Å±¡¡C
ªð¦^¦Cªí ¤W¤@¥DÃD