{"action":"created","issue":{"url":"https://api.github.com/repos/pydata/pandas/issues/11149","labels_url":"https://api.github.com/repos/pydata/pandas/issues/11149/labels{/name}","comments_url":"https://api.github.com/repos/pydata/pandas/issues/11149/comments","events_url":"https://api.github.com/repos/pydata/pandas/issues/11149/events","html_url":"https://github.com/pydata/pandas/pull/11149","id":107349827,"number":11149,"title":"Experimental/WIP: multi-line, not inplace eval","user":{"login":"chris-b1","id":1924092,"avatar_url":"https://avatars.githubusercontent.com/u/1924092?v=3","gravatar_id":"","url":"https://api.github.com/users/chris-b1","html_url":"https://github.com/chris-b1","followers_url":"https://api.github.com/users/chris-b1/followers","following_url":"https://api.github.com/users/chris-b1/following{/other_user}","gists_url":"https://api.github.com/users/chris-b1/gists{/gist_id}","starred_url":"https://api.github.com/users/chris-b1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chris-b1/subscriptions","organizations_url":"https://api.github.com/users/chris-b1/orgs","repos_url":"https://api.github.com/users/chris-b1/repos","events_url":"https://api.github.com/users/chris-b1/events{/privacy}","received_events_url":"https://api.github.com/users/chris-b1/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/pydata/pandas/labels/API%20Design","name":"API Design","color":"AD7FA8"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/pydata/pandas/milestones/32","html_url":"https://github.com/pydata/pandas/milestones/Next%20Major%20Release","labels_url":"https://api.github.com/repos/pydata/pandas/milestones/32/labels","id":933188,"number":32,"title":"Next Major Release","description":"after 0.16.1 of course","creator":{"login":"jreback","id":953992,"avatar_url":"https://avatars.githubusercontent.com/u/953992?v=3","gravatar_id":"","url":"https://api.github.com/users/jreback","html_url":"https://github.com/jreback","followers_url":"https://api.github.com/users/jreback/followers","following_url":"https://api.github.com/users/jreback/following{/other_user}","gists_url":"https://api.github.com/users/jreback/gists{/gist_id}","starred_url":"https://api.github.com/users/jreback/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jreback/subscriptions","organizations_url":"https://api.github.com/users/jreback/orgs","repos_url":"https://api.github.com/users/jreback/repos","events_url":"https://api.github.com/users/jreback/events{/privacy}","received_events_url":"https://api.github.com/users/jreback/received_events","type":"User","site_admin":false},"open_issues":914,"closed_issues":75,"state":"open","created_at":"2015-01-13T10:53:19Z","updated_at":"2015-10-08T11:09:56Z","due_on":"2016-01-31T05:00:00Z","closed_at":null},"comments":2,"created_at":"2015-09-19T18:45:31Z","updated_at":"2015-10-08T11:16:04Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/pydata/pandas/pulls/11149","html_url":"https://github.com/pydata/pandas/pull/11149","diff_url":"https://github.com/pydata/pandas/pull/11149.diff","patch_url":"https://github.com/pydata/pandas/pull/11149.patch"},"body":"This is just a proof of concept at this point - the idea is to allow multiple assignments within an eval block, and also include an `inplace` argument (currently default True to match old behavior, although maybe that should be changed) for chaining.\r\n\r\nwould close #9297\r\n\r\n    In [15]: df = pd.DataFrame({'a': np.linspace(0, 100), 'b': range(50)})\r\n\r\n    In [16]: df.eval(\"\"\"\r\n        ...: c = a * 2\r\n        ...: d = c / 2.0\r\n        ...: e = a + b + c\"\"\")\r\n\r\n    In [17]: df.head()\r\n    Out[17]: \r\n            a  b          c         d          e\r\n    0  0.000000  0   0.000000  0.000000   0.000000\r\n    1  2.040816  1   4.081633  2.040816   7.122449\r\n    2  4.081633  2   8.163265  4.081633  14.244898\r\n    3  6.122449  3  12.244898  6.122449  21.367347\r\n    4  8.163265  4  16.326531  8.163265  28.489796\r\n\r\n    In [18]: df.eval(\"\"\"\r\n        ...: f = e * 2\r\n        ...: g = f * 1.5\"\"\", inplace=False).head()\r\n    Out[18]: \r\n            a  b          c         d          e          f          g\r\n    0  0.000000  0   0.000000  0.000000   0.000000   0.000000   0.000000\r\n    1  2.040816  1   4.081633  2.040816   7.122449  14.244898  21.367347\r\n    2  4.081633  2   8.163265  4.081633  14.244898  28.489796  42.734694\r\n    3  6.122449  3  12.244898  6.122449  21.367347  42.734694  64.102041\r\n    4  8.163265  4  16.326531  8.163265  28.489796  56.979592  85.469388\r\n"},"comment":{"url":"https://api.github.com/repos/pydata/pandas/issues/comments/146507288","html_url":"https://github.com/pydata/pandas/pull/11149#issuecomment-146507288","issue_url":"https://api.github.com/repos/pydata/pandas/issues/11149","id":146507288,"user":{"login":"jreback","id":953992,"avatar_url":"https://avatars.githubusercontent.com/u/953992?v=3","gravatar_id":"","url":"https://api.github.com/users/jreback","html_url":"https://github.com/jreback","followers_url":"https://api.github.com/users/jreback/followers","following_url":"https://api.github.com/users/jreback/following{/other_user}","gists_url":"https://api.github.com/users/jreback/gists{/gist_id}","starred_url":"https://api.github.com/users/jreback/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jreback/subscriptions","organizations_url":"https://api.github.com/users/jreback/orgs","repos_url":"https://api.github.com/users/jreback/repos","events_url":"https://api.github.com/users/jreback/events{/privacy}","received_events_url":"https://api.github.com/users/jreback/received_events","type":"User","site_admin":false},"created_at":"2015-10-08T11:16:04Z","updated_at":"2015-10-08T11:16:04Z","body":"cc @shoyer "}}