![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Python
肆泰梓
这个作者很懒,什么都没留下…
展开
-
Numpy 数值运算
Numpy认识:是 Python 语言的一个扩展程序库,支持大量的维度数组与矩阵运算,此外也针对数组运算提供大量的数学函数库。>>> import numpy as np>>> import random0-19随机生成3行4列的数组>>> np.random.randint(0,20,(3,4))array([[15, 4, 1, 13], [ 4, 9, 9, 16], [13, 18, 8, 3原创 2021-02-23 19:47:56 · 323 阅读 · 1 评论 -
Python 滚动点击爬虫
# -*-coding:UTF-8 -*-import jsonfrom selenium import webdriverfrom lxml import etreeimport timeimport re# 滚动加载def height_All(): #每隔0.5秒刷新一次 SCROLL_PAUSE_TIME = 0.5 last_height = driver.execute_script("return document.body.scrollHeight")原创 2020-10-22 15:45:29 · 265 阅读 · 0 评论 -
Python 基础爬虫
# -*-coding:UTF-8 -*-from lxml import etreeimport requestsimport osimport jsonimport timedef getText(url): # 伪装请求头 my_headers = { 'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3原创 2020-10-22 15:45:05 · 102 阅读 · 0 评论 -
matplotlib 可视化
# 折线图import matplotlib.pyplot as pltfrom matplotlib import font_managerimport random# 中文设置,具体的位置从终端-- fc-list :lang=zh 查路径myfont=font_manager.FontProperties(fname=r'/System/Library/Fonts/PingFang.ttc')x=range(0,120)y=[random.randint(20,25) for i .原创 2020-10-22 15:46:10 · 183 阅读 · 0 评论