官术网_书友最值得收藏!

Creation using NumPy functions

It is a common practice to initialize the Series object's various NumPy functions. As an example, the following uses the NumPy np.arange function to create a sequence of integer values between 4 and 8:

The np.linspace() method is similar in functionality but allows us to specify the number of values to be created between (and including) the two specified values, and with a specified number of steps:

It is also common to generate a set of random numbers using np.random.normal(). The following generates five random numbers from a normal distribution:

主站蜘蛛池模板: 岫岩| 武胜县| 荣昌县| 漳平市| 河南省| 平南县| 丰城市| 军事| 台中市| 兴义市| 庆云县| 泾源县| 黑水县| 佛冈县| 桃园市| 商水县| 牟定县| 建平县| 措美县| 鄂温| 建德市| 江西省| 遂平县| 金门县| 巩义市| 闵行区| 寻甸| 商南县| 平舆县| 故城县| 青岛市| 普兰店市| 曲松县| 丰都县| 福清市| 阿拉善右旗| 遂川县| 通江县| 平定县| 海阳市| 鹿邑县|