{"action":"opened","issue":{"url":"https://api.github.com/repos/mingyun/mingyun.github.io/issues/56","repository_url":"https://api.github.com/repos/mingyun/mingyun.github.io","labels_url":"https://api.github.com/repos/mingyun/mingyun.github.io/issues/56/labels{/name}","comments_url":"https://api.github.com/repos/mingyun/mingyun.github.io/issues/56/comments","events_url":"https://api.github.com/repos/mingyun/mingyun.github.io/issues/56/events","html_url":"https://github.com/mingyun/mingyun.github.io/issues/56","id":220462698,"number":56,"title":"Python教你用matplotlib画个心心撩妹","user":{"login":"mingyun","id":4477751,"avatar_url":"https://avatars1.githubusercontent.com/u/4477751?v=3","gravatar_id":"","url":"https://api.github.com/users/mingyun","html_url":"https://github.com/mingyun","followers_url":"https://api.github.com/users/mingyun/followers","following_url":"https://api.github.com/users/mingyun/following{/other_user}","gists_url":"https://api.github.com/users/mingyun/gists{/gist_id}","starred_url":"https://api.github.com/users/mingyun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mingyun/subscriptions","organizations_url":"https://api.github.com/users/mingyun/orgs","repos_url":"https://api.github.com/users/mingyun/repos","events_url":"https://api.github.com/users/mingyun/events{/privacy}","received_events_url":"https://api.github.com/users/mingyun/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-04-09T10:35:18Z","updated_at":"2017-04-09T10:35:18Z","closed_at":null,"body":"```js\r\nimport matplotlib.pyplot as plt\r\nimport numpy as np\r\nimport math\r\npi = math.pi\r\nt = np.arange(0,2*pi,0.001)\r\nr = np.frompyfunc(round,1,1)\r\nsin = np.frompyfunc(math.sin,1,1)\r\ncos = np.frompyfunc(math.cos,1,1)\r\n#y = sin(x)*(abs(cos(x)))**0.5/(sin(x)+1.4)-2*sin(x)+2\r\n'''\r\ny = 2*cos(t)-cos(2*t)\r\nx = 2*sin(t)-sin(2*t)\r\n'''\r\nx=sin(t)\r\nc=cos(t)\r\np=x**2\r\ny=c+p**(1/3)\r\nplt.plot(x, y,color='r', linewidth=9)\r\nplt.fill(x,y,color='r')\r\nplt.title(\"my heart for you\")\r\nax = plt.subplot(111)\r\nax.spines['right'].set_color('none')\r\nax.spines['top'].set_color('none')\r\nax.spines['bottom'].set_color('none')\r\nax.spines['left'].set_color('none')\r\nplt.xlim(-1.2,1.2),plt.xticks([])\r\nplt.yticks([])\r\nplt.show()\r\n#https://zhuanlan.zhihu.com/p/25575403?fc=1&group_id=830778225423683584#comment-260961042\r\n```"}}
{"actor":{"display_login":"mingyun"}}