当前位置: 首页 > wzjs >正文

做婚恋交友网站模板温州seo优化

做婚恋交友网站模板,温州seo优化,成都网站建设有名的,网站建设的风险分析1、std 用于计算 DataFrame 中数值的标准差。 DataFrame.std(axis0, skipnaTrue, ddof1, numeric_onlyFalse, **kwargs) 描述说明axis {0 或 ‘index’, 1 或 ‘columns’, None}, 默认为 0。这个参数决定了计算标准差是在哪个轴上进行: 如果 axis0 或 axisindex&…

1、std

        用于计算 DataFrame 中数值的标准差。

DataFrame.std(axis=0, skipna=True, ddof=1, numeric_only=False, **kwargs)
描述说明
axis

{0 或 ‘index’, 1 或 ‘columns’, None}, 默认为 0。这个参数决定了计算标准差是在哪个轴上进行:

如果 axis=0 或 axis='index',则对每列进行计算,返回一个 Series,其 索引为列名,值为每列的标准差。

如果 axis=1 或 axis='columns',则对每行进行计算,返回一个 Series, 其索引为行索引,值为每行的标准差。

skipna布尔值,默认为 True。如果为 True,则在计算标准差时会忽略 NaN 值。
ddof整数,默认为 1。Delta Degrees of Freedom,计算样本标准差时使用的无 偏估计的自由度修正。对于整个群体的标准差, ddof 应该设置为 0。
numeric_only布尔值,默认为 False。如果为 True,则只对数值列进行计算, 忽略非数值列。
**kwargs其他关键字参数。这些参数通常用于兼容性或特殊用途,通常不需 要。
import pandas as pd
import numpy as np
df = pd.DataFrame({'A': [1, 2, 3, 4],'B': [5, 6, 7, 8],
})
sum_per_column = df.std()
print("std per column:")
print(sum_per_column)
std per column:
A    1.290994
B    1.290994
dtype: float64

2 、quantile

        用于计算 DataFrame 中数值的分位数。

DataFrame.quantile(q=0.5, axis=0, numeric_only=False, interpolation='linear', method='single')
描述说明
q可以是单个浮点数或浮点数列表,默认为 0.5。要计算的的分位数,应该在 0 到 1 之间。例如,q=0.5 表示中位数。
axis

{0 或 ‘index’, 1 或 ‘columns’, None}, 默认为 0。这个参数决定了计算分位数是在哪个轴上进行:

如果 axis=0 或 axis='index',则对每列进行计算,返回一个 Series,其 索引为列名,值为每列的分位数。

如果 axis=1 或 axis='columns',则对每行进行计算,返回一个 Series, 其索引为行索引,值为每行的分位数。

numeric_only布尔值,默认为 False。如果为 True,则只对数值列进行计算, 忽略非数值列。
interpolation

{‘linear’, ‘lower’, ‘higher’, ‘midpoint’, ‘nearest’}, 默认为 ‘linear’。这个参数决定了分位数在数据不包含精确分位数值时的插值方法:

‘linear’: 线性插值。

‘lower’: 选择小于分位数的最大值。

‘higher’: 选择大于分位数的最小值。

‘midpoint’: 选择两个相邻数据的中间值。

‘nearest’: 选择最接近分位数的值。

method

{‘single’, ‘table’}, 默认为 ‘single’。这个参数决定了计算分位数的方法:

‘single’: 对每列或每行单独计算分位数。

‘table’: 使用整个表的分位数。选择table时,插值方法只能是higher、 lower、nearest之一。

import pandas as pd
import numpy as np
df = pd.DataFrame({'A': [1, 2, 3, 4],'B': [5, 6, 7, 8],
})
sum_per_column = df.quantile()
print("quantile per column:")
print(sum_per_column)
quantile per column:
A    2.5
B    6.5
Name: 0.5, dtype: float64

3、 cummax

        用于计算 DataFrame 中数值的累积最大值。

DataFrame.cummax(axis=0, skipna=True, *args, **kwargs)
描述说明
axis

{0 或 ‘index’, 1 或 ‘columns’, None}, 默认为 0。这个参数决定了计算累积最大值是在哪个轴上进行:

如果 axis=0 或 axis='index',则对每列进行计算,返回一个 Series,其 索引为列名,值为每列的累积最大值。

如果 axis=1 或 axis='columns',则对每行进行计算,返回一个 Series, 其索引为行索引,值为每行的累积最大值。

skipna布尔值,默认为 True。如果为 True,则在计算累积最大值时会忽略 NaN 值。
*args 和 **kwargs其他关键字参数。这些参数通常用于兼容性或特殊用途,通常不需 要。
import pandas as pd
import numpy as np# 创建一个 DataFrame
df = pd.DataFrame({'A': [1, 2, np.nan, 4, 5],'B': [5, np.nan, 3, 2, 1],
})print(df)# 计算每列的累积最大值
cummax_per_column = df.cummax(axis=0)
print("Cumulative max per column:")
print(cummax_per_column)# 计算每行的累积最大值
cummax_per_row = df.cummax(axis=1)
print("\nCumulative max per row:")
print(cummax_per_row)
     A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  2.0
4  5.0  1.0
Cumulative max per column:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  5.0
3  4.0  5.0
4  5.0  5.0Cumulative max per row:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  4.0
4  5.0  5.0

4、 cummin

 用于计算 DataFrame 中数值的累积最小值。

DataFrame.cummin(axis=0, skipna=True, *args, **kwargs)
描述说明
axis

{0 或 ‘index’, 1 或 ‘columns’, None}, 默认为 0。这个参数决定了计算累积最小值是在哪个轴上进行:

如果 axis=0 或 axis='index',则对每列进行计算,返回一个 Series,其 索引为列名,值为每列的累积最小值。

如果 axis=1 或 axis='columns',则对每行进行计算,返回一个 Series, 其索引为行索引,值为每行的累积最小值。

skipna布尔值,默认为 True。如果为 True,则在计算累积最小值时会忽略 NaN 值。
*args 和 **kwargs其他关键字参数。这些参数通常用于兼容性或特殊用途,通常不需 要。
import pandas as pd
import numpy as np# 创建一个 DataFrame
df = pd.DataFrame({'A': [1, 2, np.nan, 4, 5],'B': [5, np.nan, 3, 2, 1],
})print(df)# 计算每列的累积最小值
cummin_per_column = df.cummin(axis=0)
print("Cumulative min per column:")
print(cummax_per_column)# 计算每行的累积最小值
cummin_per_row = df.cummin(axis=1)
print("\nCumulative min per row:")
print(cummax_per_row)
     A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  2.0
4  5.0  1.0
Cumulative min per column:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  5.0
3  4.0  5.0
4  5.0  5.0Cumulative min per row:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  4.0
4  5.0  5.0

5、 cumsum

         用于计算 DataFrame 中数值的累积 和。

DataFrame.cumsum(axis=0, skipna=True, *args, **kwargs)
描述说明
axis

{0 或 ‘index’, 1 或 ‘columns’, None}, 默认为 0。这个参数决定了计算累积 和是在哪个轴上进行:

如果 axis=0 或 axis='index',则对每列进行计算,返回一个 Series,其 索引为列名,值为每列的累积 和。

如果 axis=1 或 axis='columns',则对每行进行计算,返回一个 Series, 其索引为行索引,值为每行的累积 和。

skipna布尔值,默认为 True。如果为 True,则在计算累积 和时会忽略 NaN 值。
*args 和 **kwargs其他关键字参数。这些参数通常用于兼容性或特殊用途,通常不需 要。
import pandas as pd
import numpy as np# 创建一个 DataFrame
df = pd.DataFrame({'A': [1, 2, np.nan, 4, 5],'B': [5, np.nan, 3, 2, 1],
})print(df)# 计算每列的累积和
cumsum_per_column = df.cumsum(axis=0)
print("Cumulative sum per column:")
print(cummax_per_column)# 计算每行的累积和
cumsum_per_row = df.cumsum(axis=1)
print("\nCumulative sum per row:")
print(cummax_per_row)
     A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  2.0
4  5.0  1.0
Cumulative sum per column:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  5.0
3  4.0  5.0
4  5.0  5.0Cumulative sum per row:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  4.0
4  5.0  5.0

6、 cumprod

         用于计算 DataFrame 中数值的累积乘积。

DataFrame.cumprod(axis=0, skipna=True, *args, **kwargs)
描述说明
axis

{0 或 ‘index’, 1 或 ‘columns’, None}, 默认为 0。这个参数决定了计算累积乘积是在哪个轴上进行:

如果 axis=0 或 axis='index',则对每列进行计算,返回一个 Series,其 索引为列名,值为每列的累积乘积。

如果 axis=1 或 axis='columns',则对每行进行计算,返回一个 Series, 其索引为行索引,值为每行的累积乘积。

skipna布尔值,默认为 True。如果为 True,则在计算累积乘积时会忽略 NaN 值。
*args 和 **kwargs其他关键字参数。这些参数通常用于兼容性或特殊用途,通常不需 要。
import pandas as pd
import numpy as np# 创建一个 DataFrame
df = pd.DataFrame({'A': [1, 2, np.nan, 4, 5],'B': [5, np.nan, 3, 2, 1],
})print(df)# 计算每列的累积乘积
cumprod_per_column = df.cumprod(axis=0)
print("Cumulative sum per column:")
print(cummax_per_column)# 计算每行的累积乘积
cumprod_per_row = df.cumprod(axis=1)
print("\nCumulative sum per row:")
print(cummax_per_row)
     A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  2.0
4  5.0  1.0
Cumulative sum per column:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  5.0
3  4.0  5.0
4  5.0  5.0Cumulative sum per row:A    B
0  1.0  5.0
1  2.0  NaN
2  NaN  3.0
3  4.0  4.0
4  5.0  5.0

 

http://www.dtcms.com/wzjs/518588.html

相关文章:

  • 个人博客html代码seo站内优化培训
  • 一个网站同时做竞价和seoebay欧洲站网址
  • 江门市专业做网站公司重庆网站排名推广
  • 品牌网官网商丘 峰少 seo博客
  • 国外 家具 网站模板长沙网站seo排名
  • 学校网站群建设方案安康地seo
  • 大专毕业设计网站灰色词排名推广
  • 什么网站做简历免费下载郑州网络营销顾问
  • 公司首页模板深圳网站seo推广
  • 玉林市城市建设投资有限公司网站2021全国大学生营销大赛
  • 自己怎么做百度网站空间谷歌竞价排名推广公司
  • 云浮网站网站建设seo的优化原理
  • 怎么制作一个简单的网站谷歌地图下载
  • 荣昌集团网站建设外贸网站推广
  • 深远互动 网站建设磁力链接搜索引擎2021
  • 外贸先做网站还是开公司搜索引擎查询
  • 建设购物网站需要多少钱看今天的新闻
  • 网站建设的行业客户个人网页免费域名注册入口
  • 简述电子政务系统网站建设的基本过程网络推广优化
  • 网站建设 网页2023年8月份新冠症状
  • 暴雪游戏排行榜前十名seo策略是什么意思
  • 山东外贸网站建设是什么seo策略什么意思
  • 安徽网站开发武汉疫情最新动态
  • 网站开发未按合同约定工期完工网站软文推广范文
  • 做图书网站赚钱吗产品seo是什么意思
  • 织梦dedecms大气微电影网站模板crm系统网站
  • 免费做公司手机网站网站收录查询系统
  • 南充建设企业网站网站怎么找
  • wordpress菜单相对地址搜索引擎优化公司
  • 快速建站服务谷歌三件套