python
文章平均质量分 53
yandao
“我是谁”、“我在哪”、“我要去哪儿”
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
python基础整理复习五(爬虫)
引入库 1.request来获取页面内容 https://requests.readthedocs.io/zh_CN/latest/ pip install -i https://pypi.tuna.tsinghua.edu.cn/simple request 2.BeautifulSoup https://beautifulsoup.readthedocs.io/zh_CN/v4.4.0/ pip install -i https://pypi.tuna.tsinghua.edu.cn/simple bs原创 2021-01-31 20:34:29 · 131 阅读 · 0 评论 -
python基础整理复习四(数据库mysql)
安装 #python2 pip install MySQL-python #python3 pip install PyMySQL -i https://pypi.tuna.tsinghua.edu.cn/simple 连接数据库 #连接数据库 DATABASE={ 'host':'localhost', 'database':'python', 'user':'root', 'password':'########', 'charset':'utf8mb4' }原创 2021-01-29 10:03:28 · 179 阅读 · 0 评论 -
python基础整理三(pandas,matplotlib)
通过指定url安装指定包 pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pandas pip install -i https://pypi.tuna.tsinghua.edu.cn/simple matplotlib pip install -i https://pypi.tuna.tsinghua.edu.cn/simple scipy #引入scipy的目的是plot.kde()需要用 pandas[数据处理] 1. 准备 导入使原创 2021-01-27 00:30:49 · 327 阅读 · 0 评论 -
python基础整理二(numpy)
通过指定url安装指定包 pip install -i https://pypi.tuna.tsinghua.edu.cn/simple numpy numpy[数据处理] 数组可以存储一种类型的数据,列表可以存储任意类型的数据 import array array.array('i',range(10)) #i代表整数类型 array('i', [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]) a =array.array('i',range(10)) a[0] 0 a[0]=10 a原创 2021-01-24 23:11:43 · 178 阅读 · 0 评论 -
python使用jupyter notebook
安装 pip install -i https://pypi.tuna.tsinghua.edu.cn/simple jupyter 启动 jupyter notebook [I 21:54:27.997 NotebookApp] Writing notebook server cookie secret to D:\Users\LENOVO\AppData\Roaming\jupyter\runtime\notebook_cookie_secret [I 21:54:28.615 NotebookApp原创 2021-01-24 22:10:08 · 526 阅读 · 3 评论 -
python基础整理一
python的特性 1.python语法简单,容易理解,容易学习 2.跨平台,可以在windows,linux,mac os 3.可以做网站、爬虫、大数据处理 4.拥有强大的第三方库numpy,panda... python 之禅 输入import this >>>import this The Zen of Python, by Tim Peters Beautiful is better than ugly. Explicit is better than implicit. Sim原创 2021-01-19 12:53:05 · 291 阅读 · 1 评论 -
记录pyspark不能访问
由于配置了JAVA_HOME的路径中有空格所以导致pyspark不能访问 解决办法 Program Files转换为Progra~1 有的建议用双引号把有空格的路径括起来 Program Files->"Program Files" 测试没有起作用 在pyspark不能使用的时候,提示的信息往往不是很明显: D:\Python\test>python WordCount2.py 此时不应有 Files"\Java\jdk1.8.0_231"=="x"。 Traceback (most rece原创 2020-12-21 00:31:04 · 480 阅读 · 0 评论
分享