-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathScrapeUrlTable2Pandas.koi
More file actions
1 lines (1 loc) · 12.3 KB
/
ScrapeUrlTable2Pandas.koi
File metadata and controls
1 lines (1 loc) · 12.3 KB
1
{"nodes":[{"nid":6,"uid":"custom","category":"function","type":"pandas2Excel","x":802,"y":195,"fields":{"in":[{"name":"start"}],"out":[{"name":"pass"}]},"python":"@on_start\ndef pandaExcelDump(*args,**kwargs):\n kwargs['Data'].to_excel({Paths1d2f3}+{Filename6kl5hte})\n return kwargs","python_import":"import pandas as pd","python_exec":"pandaExcelDump","settings":[{"key":"Filename6kl5hte","label":"Filename (ex. file.xlsx)","props":{"required":true}},{"key":"Paths1d2f3","label":"Save location (blank saves in the same directory as the executed file)","props":{"required":true}}],"data":{"Filename6kl5hte":"'test.xlsx'","Paths1d2f3":"''"},"description":"This Node takes kwargs['PData'] and dumps its contents with a user defined name and to a user defined location in the xlsx file format. This Node does not clear kwargs['PData'] Requires Pandas\n\n","showExecution":false,"showDescription":true,"showImports":false,"showFunction":false,"toggleMarkdown":false,"toggleUserDialog":false,"stringDialog":"[{\"key\":\"Filename6kl5hte\",\"label\":\"Filename (ex. file.xlsx)\",\"props\":{\"required\":true}},{\"key\":\"Paths1d2f3\",\"label\":\"Save location (blank saves in the same directory as the executed file)\",\"props\":{\"required\":true}}]","stringPins":"{\"in\":[{\"name\":\"start\"}],\"out\":[{\"name\":\"pass\"}]}","togglePins":false,"version":"0.0.1","headerStyle":{"background":"#adac15"}},{"nid":0,"version":"1.0.0","uid":1,"category":"function","type":"Start","x":10,"y":10,"headerStyle":{"background":""},"fields":{"in":[],"out":[{"name":"start"}]},"python":"def start():\n return {'Start':True,'Settings':{'Verbose':True},'Status':{}}\n","python_import":"","python_exec":"start","settings":[],"icon":"./static/media/start.c59e7ea6.svg","data":{},"kwargs":{},"description":"\n\nThe Start Node \n\n_This node is required to run a standard nodegraph that use the onstart decorator_\n\n\n## This Node Changes\n\nThis node initializes all standard kwargs\n\n## Getting This Node to Work\n\nThis node takes no inputs and only one can be connected in any given nodegraph. It sets Verbose to True by default, this setting outputs nodes run in the terminal when they are running and other debugging information. \n\n\n### Input State Requirements\n\nNone\n\n### Output State\n\n```python\nkwargs={\n Start: {},\n Settings: {Verbose:True},\n Data:{},\n Status: {}\n }\n```\n\n## Example Usage\n\n\n\n## Todo\n\n## Known Issues\n\nNo known Issues\n\n## License\n\nUsage of this node is provided under the [MIT License](http://http//opensource.org/licenses/mit-license.php). See LICENSE for the full details.\n\nThis node signifies the beginning of your node graph by the streme server. The start node passes true from the start output pin initiating the nodes it is connected to."},{"nid":1,"version":"1.0.0","uid":10,"category":"function","type":"Stop","x":1022,"y":108,"headerStyle":{"background":"#ad1562"},"fields":{"in":[{"name":"start"}],"out":[]},"python":"@on_start\ndef stop(*args,**kwargs):\n print('exiting')\n sys.exit()\n ","python_import":"import sys","python_exec":"stop","settings":[],"icon":"./static/media/stop.a2171794.svg","data":{},"kwargs":{},"description":"This node ends the existing node experiment. It will not stop processes that have started in parallel using split nodes."},{"nid":3,"version":"0.0.1","uid":5,"category":"logical","type":"lxmlParseUrl","x":147,"y":106,"fields":{"in":[{"name":"start"}],"out":[{"name":"pass"}]},"python":"@on_start\ndef lxmlParseUrl|||(*args,**kwargs):\n page = requests.get('{userinput}')\n kwargs['Data'] = lh.fromstring(page.content)\n return kwargs","python_import":"import requests\nimport lxml.html as lh\n","python_exec":"lxmlParseUrl|||","settings":[{"key":"userinput","label":"url of Page you want to Parse"}],"icon":"./static/media/blankNode.38260d5b.svg","data":{"userinput":"https://www.w3schools.com/html/html_tables.asp"},"kwargs":{},"description":"\n\nInclude a brief title for your node and a small description. \n\n_One Sentence on what problem your node solves_\n\n[YOUR GITHUB PAGE FOR THE NODE SOURCE](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#links)\n\n## This Node Changes\n\n\n\nThis node takes a Pandas Dataframe in outputs and excel file and returns kwargs unchanged to the next node.\n\n## Getting This Node to Work\n\nThis node will work if it provided with a Dataframe in kwargs{Data} and Pandas is installed\n\n### Installing Dependencies\n\nThis node requires Pandas. Pandas can be installed using pip in your terminal \n\n```bash\npip install pandas\n```\n\nif you have python2 and python3 installed\n\n```bash\npip3 install pandas\n```\n\nIf you are using Anaconda (Pandas is already installed in the default setup):\n\n```bash\nconda install pandas\n```\n\n### Input State Requirements\n\nThis node requires that kwargs{Data} be a [Pandas Dataframe](https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.html)\n\n```python\nkwargs={\n Start: True,\n Settings: Any,\n Data: Any Pandas Dataframe,\n Status: Any,\n }\n```\n\n### Output State\n\n```python\nkwargs={\n Start: No Change,\n Settings: No Change,\n Data: No Change,\n Status: No Change\n }\n```\n\n## Example Usage\n\nCheck out this simple demo of this node working : [Download Koi](https://mykoilocation.com)\n\n\n\n## Todo\n\n- Something\n\n- Another Thing\n\n- Something Else\n\n## Known Issues\n\n- We coded it poorly\n\n- Works only on the first of every month that is also within 5 days of the summer solstice \n\n## License\n\nUsage of this node is provided under the [MIT License](http://http//opensource.org/licenses/mit-license.php). See LICENSE for the full details.\n","showExecution":false,"showDescription":true,"showImports":false,"showFunction":false,"toggleMarkdown":false,"toggleUserDialog":false,"stringDialog":"[{\"key\":\"userinput\",\"label\":\"url of Page you want to Parse\"}]","stringPins":"{\"in\":[{\"name\":\"start\"}],\"out\":[{\"name\":\"pass\"}]}","togglePins":false,"headerStyle":{"background":"#15ad60"}},{"nid":5,"uid":"custom","category":"logical","type":"lxmlTable2Pandas","x":596,"y":91,"fields":{"in":[{"name":"start"}],"out":[{"name":"pass"}]},"python":"@on_start\ndef lxmlTable2Pandas|||(*args,**kwargs):\n kwargs['Data']=pd.read_html(lh.tostring(kwargs['Data']))[0]\n print(kwargs['Data'])\n return kwargs","python_import":"import pandas as pd\nimport lxml.html as lh","python_exec":"lxmlTable2Pandas|||","settings":[],"icon":"./static/media/blankNode.38260d5b.svg","data":{},"description":"\n\nInclude a brief title for your node and a small description. \n\n_One Sentence on what problem your node solves_\n\n[YOUR GITHUB PAGE FOR THE NODE SOURCE](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#links)\n\n## This Node Changes\n\n\n\nThis node takes a Pandas Dataframe in outputs and excel file and returns kwargs unchanged to the next node.\n\n## Getting This Node to Work\n\nThis node will work if it provided with a Dataframe in kwargs{Data} and Pandas is installed\n\n### Installing Dependencies\n\nThis node requires Pandas. Pandas can be installed using pip in your terminal \n\n```bash\npip install pandas\n```\n\nif you have python2 and python3 installed\n\n```bash\npip3 install pandas\n```\n\nIf you are using Anaconda (Pandas is already installed in the default setup):\n\n```bash\nconda install pandas\n```\n\n### Input State Requirements\n\nThis node requires that kwargs{Data} be a [Pandas Dataframe](https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.html)\n\n```python\nkwargs={\n Start: True,\n Settings: Any,\n Data: Any Pandas Dataframe,\n Status: Any,\n }\n```\n\n### Output State\n\n```python\nkwargs={\n Start: No Change,\n Settings: No Change,\n Data: No Change,\n Status: No Change\n }\n```\n\n## Example Usage\n\nCheck out this simple demo of this node working : [Download Koi](https://mykoilocation.com)\n\n\n\n## Todo\n\n- Something\n\n- Another Thing\n\n- Something Else\n\n## Known Issues\n\n- We coded it poorly\n\n- Works only on the first of every month that is also within 5 days of the summer solstice \n\n## License\n\nUsage of this node is provided under the [MIT License](http://http//opensource.org/licenses/mit-license.php). See LICENSE for the full details.\n","showExecution":false,"showDescription":true,"showImports":false,"showFunction":false,"toggleMarkdown":false,"toggleUserDialog":false,"stringDialog":"[]","stringPins":"{\"in\":[{\"name\":\"start\"}],\"out\":[{\"name\":\"pass\"}]}","togglePins":false,"headerStyle":{"background":"#15ad60"}},{"nid":17,"uid":"custom","category":"logical","type":"lxmlGetID","x":357,"y":99,"fields":{"in":[{"name":"start"}],"out":[{"name":"pass"}]},"python":"@on_start\ndef lxmlFindAll|||(*args,**kwargs):\n kwargs['Data'] = kwargs['Data'].get_element_by_id({userinput})\n return kwargs","python_import":" import lxml.html as lh","python_exec":"lxmlFindAll|||","settings":[{"key":"userinput","label":"Search string"}],"icon":"./static/media/blankNode.38260d5b.svg","data":{"userinput":"'customers'"},"description":"\n\nInclude a brief title for your node and a small description. \n\n_One Sentence on what problem your node solves_\n\n[YOUR GITHUB PAGE FOR THE NODE SOURCE](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#links)\n\n## This Node Changes\n\n\n\nThis node takes a Pandas Dataframe in outputs and excel file and returns kwargs unchanged to the next node.\n\n## Getting This Node to Work\n\nThis node will work if it provided with a Dataframe in kwargs{Data} and Pandas is installed\n\n### Installing Dependencies\n\nThis node requires Pandas. Pandas can be installed using pip in your terminal \n\n```bash\npip install pandas\n```\n\nif you have python2 and python3 installed\n\n```bash\npip3 install pandas\n```\n\nIf you are using Anaconda (Pandas is already installed in the default setup):\n\n```bash\nconda install pandas\n```\n\n### Input State Requirements\n\nThis node requires that kwargs{Data} be a [Pandas Dataframe](https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.html)\n\n```python\nkwargs={\n Start: True,\n Settings: Any,\n Data: Any Pandas Dataframe,\n Status: Any,\n }\n```\n\n### Output State\n\n```python\nkwargs={\n Start: No Change,\n Settings: No Change,\n Data: No Change,\n Status: No Change\n }\n```\n\n## Example Usage\n\nCheck out this simple demo of this node working : [Download Koi](https://mykoilocation.com)\n\n\n\n## Todo\n\n- Something\n\n- Another Thing\n\n- Something Else\n\n## Known Issues\n\n- We coded it poorly\n\n- Works only on the first of every month that is also within 5 days of the summer solstice \n\n## License\n\nUsage of this node is provided under the [MIT License](http://http//opensource.org/licenses/mit-license.php). See LICENSE for the full details.\n","headerStyle":{"background":"#adac15"},"showExecution":false,"showDescription":true,"showImports":false,"showFunction":false,"toggleMarkdown":false,"toggleUserDialog":false,"stringDialog":"[{\"key\":\"userinput\",\"label\":\"Search string\"}]","stringPins":"{\"in\":[{\"name\":\"start\"}],\"out\":[{\"name\":\"pass\"}]}","togglePins":false}],"connections":[{"from_node":0,"from":"start","to_node":3,"to":"start"},{"from_node":5,"from":"pass","to_node":6,"to":"start"},{"from_node":6,"from":"pass","to_node":1,"to":"start"},{"from_node":3,"from":"pass","to_node":17,"to":"start"},{"from_node":17,"from":"pass","to_node":5,"to":"start"}],"title":"ScrapeUrlTable2Pandas","showPopup":false,"current":11,"count":18,"servers":{},"serverselection":null}