Commit Graph

41 Commits

Author SHA1 Message Date
Dietrich Brunn 22cf964b6e Small improvements to `signal.firwin` docstr
* change `plt.subplots(..., tight_layout=True)` into `plt.subplots(..., layout="constrained")`.`
* Fix typos.

[docs only]
2025-09-17 11:54:29 -04:00
Dietrich Brunn 5cbe936732 DOC/BUG: signal.firwin: Improve documentation
* Clarify behavior of `pass_zero` parameter. Closes #19291.
* Make example section more useful by adding examples with plots which illustrate the behavior of the significant parameters.
* Improve `firwin` and `firwin2` plots in `signal.rst`.

[docs only]
2025-09-17 11:54:29 -04:00
Jost Migenda 252124e819
DOC: remove help(integrate) output (#23492) 2025-08-22 11:53:25 +02:00
William Zijie Zhang 34d91ce06d
STY: fix lint rule UP031 (#21987)
Co-authored-by: Lucas Colley <lucas.colley8@gmail.com>
2025-01-22 08:26:09 +00:00
Dan Schult 1d5ca99ae1
ENH: sparse.linalg: convert sparse.linalg to use sparray internally (#21710)
* convert sparse.linalg to use sparray internally

* fix found errors

* workaround pydata and too-fast convergence in some tests

* typo

* make A symmetric to test real eig like name of test. Maybe avoid spurious failures too

* make scalar vx matmul clear in test

* include reviewer suggestions

* fix random_array changes to include rng seed. Will change migration guide in another PR to address this.

* fix issubclass usage

* update docs in _dsolve/linsolve.py [docs only]
2024-11-04 23:30:05 -05:00
Dietrich Brunn 446a9dbcab
DOC: Improving "Spectral Analysis" section in User Guide (#19488)
* DOC: Improving "Spectral Analysis" section in User Guide

* DOC: Remove header comments of plot scripts for "Spectral Analysis" section in file signal.rst.

* Small corrections.

* * Added link to "Spectral Analysis" section in docstrings of `csd()`, `periodogram()` and `welch()`
* Changed name of "power spectrum" to "squared magnitude spectrum" in `periodogram()` and `welch()` in docstrings for consistency.
* Fixed small typos.

* Fix two linter errors.

* Fixed Typo doc/source/tutorial/signal.rst

Co-authored-by: Eric Larson <larson.eric.d@gmail.com>

* Fixed Typo in doc/source/tutorial/signal.rst (2)

Co-authored-by: Eric Larson <larson.eric.d@gmail.com>

* Fixed typo in plot doc/source/tutorial/examples/signal_SpectralAnalysis_ContinuousSpectralRepresentations.py

Co-authored-by: Eric Larson <larson.eric.d@gmail.com>

* Small tex improvement doc/source/tutorial/signal.rst

Co-authored-by: Eric Larson <larson.eric.d@gmail.com>

* Imrpove wording in  doc/source/tutorial/signal.rst

Co-authored-by: Eric Larson <larson.eric.d@gmail.com>

* Change "impulse response" to "frequency response" in  doc/source/tutorial/examples/signal_SpectralAnalysis_SpectrumPhaseDelay.py

Co-authored-by: Eric Larson <larson.eric.d@gmail.com>

* * Fixed wording for  '"onesided" spectral representation' in signal.rst
* Made width difference of the lobes of the plot generated in signal_SpectralAnalysis_PeriodogramWelch.py more apparent.

---------

Co-authored-by: Eric Larson <larson.eric.d@gmail.com>
2024-01-08 12:05:18 -05:00
lucascolley 9cf72e4599 MAINT: lint: clean-up for UP rules 2023-11-21 13:18:24 +00:00
lucascolley 3428e85061 MAINT/DOC/BENCH: optimize: fix linter errors 2023-11-10 21:43:59 +00:00
Zaikun ZHANG 7eea3caaa6
Correct the comments about ` fmin_powell` in `scipy/optimize` (#18120)
* Correct the comment about `fmin_powell` in `optimize/__init__.py`

* Correct the comment about `fmin_powell` in `scipy/doc/source/tutorial/examples/5-1`
2023-03-09 14:06:56 +01:00
Nicholas McKibben b39dfaae25
Merge pull request #15297 from mdhaber/bounds_improvements
ENH: optimize: improvements to `Bounds` class
2022-01-10 08:30:51 -07:00
Jan-Hendrik Müller a0d44d5be1
DOC: added example for morphology: generate_binary_structure, binary_dilation and erosion (#15244)
Co-authored-by: Pamphile Roy <roy.pamphile@gmail.com>
2022-01-07 16:56:39 +01:00
Matt Haberland 1dd843d4d6 DOC: remove erroneous basin_hopping example from tutorial 2021-12-31 18:44:32 -08:00
Matt Haberland dd9cfb0506
Undo all unnecessary changes to tutorial to avoid sphinx explosion 2021-12-31 16:59:28 -08:00
Matt Haberland d6b223675b DOC: optimize: correct basinhopping tutorial example 2021-12-31 16:16:50 -08:00
Jan-Hendrik Müller 1d80deaac2
DOC: 3D example for gaussian_filter (#15037)
Co-authored-by: Pamphile ROY <roy.pamphile@gmail.com>
2021-11-15 19:57:29 +01:00
Pamphile ROY 71b4bc0e83
MAINT: Refactor optimization methods to use scipy.stats.qmc (#13469)
* CLN: Refactor shgo to use qmc.Sobol

* CLN: Refactor differentialevolution to use qmc.LHS

* ENH: add other QMC methods as init in differentialevolution

* CLN/DOC: revert original LHS and document sobol, halton options

* FIX: init choice

* MAINT: change warning filtering

* TST: fix seed for backward compatibility with numpy 1.6

* TST/FIX: incorrect number of samples for Sobol' and remove warning filter for Sobol'

* DOC: fix wrong number of sample for sobol in shgo example

* FIX: Sobol' number of samples in doc and iteration logic

* FIX: Update self.n

* FIX: doctests

* FIX: tests suite

* FIX: default n to None and Sobol iterations without scrambling

* ENH: because n is constant fast forward is implicitly done and not needed here

* ENH: halton remove sobol sampling function

* FIX/DOC/TST: int for QMC ns, corresponding tests and minor doc

* FIX/TST: warning in dual_annealing test on windows

* DOC/TST: rewording about Sobol' and change init tests

* DOC/MAINT: barnard_exact n for shgo and round to power of 2 for sobol

* MAINT: circular imports

* FIX: missing backslash

* MAINT: review from andyfaff

* DOC: review from andyfaff
2021-04-19 08:35:45 -04:00
Pamphile ROY 9492369e7f
DOC: remove seed in examples (#13863) 2021-04-18 21:27:05 +02:00
Recursing 4a29296610 MAINT: Rename integrate.simps to simpsons in examples 2021-02-28 23:22:07 +01:00
Gregory Lee 2cf2772b78 typo order=03 -> order=3 in boundary modes plot [skip CI][CI skip] 2020-11-10 16:15:11 -05:00
Gregory Lee a41047ff80 DOC: add grid-constant to docstrings and ndimage tutorial 2020-11-10 08:43:45 -05:00
Gregory R. Lee 81d5e7acf9
Fix spline interpolation boundary handling for modes reflect and wrap (#12767)
* ENH: add mode NI_EXTEND_WRAP_GRID to map_coordinates

* MAINT: remove duplicated code for the mirror extension case

The next step is to use other modes here in addition to the existing
map_coordinates call above

* pass the mode argument to spline_filter1d calls in interpolation.py

* BUG: use wrap and reflect spline boundary conditions appropriately

* use grid-wrap instead of wrap-grid as suggested in gh-206

add alias grid-mirror for reflect

TST: test_splines.py now needs to use 'grid-wrap' rather than 'wrap'

* ENH: modify NI_ZoomShift to support all spline boundary modes as well

the same approach for spline_mode as used in NI_GeometricTransform is repeated

* BUG: For line buffer functions set grid-wrap equivalent to wrap

* TST: add map_coordinates boundary tests for new modes

TST: add new zoom and shift tests

TST: add reflect via affine shift test

* DOC: update ndimage.interpolation docstrings

* DOC: add boundary and interpolation grid figures ndimage tutorial

* DOC: pep8 in tutorial examples

* DOC: update plot_interp_grid.py tickmarks for matplotlib 3.3 compatibility

* DOC: update tutorial on reviewer feedback

* DOC: link to boundary mode illustrations from interpolation docstrings

DOC: mention grid-mirror and grid-wrap synonyms in ndimage filter docstrings

DOC: update mode descripts in the ndimage filter tutorial text
2020-11-10 07:43:30 -05:00
Ralf Gommers 5621f933e8
MAINT: rename trapz and cumtrapz to (cumulative_)trapezoid (#12934)
* MAINT: rename cumtrapz to cumulative_trapezoid

Keep cumtrapz as an undocumented alias.  Addresses part of gh-12924.

* MAINT: rename integrate.trapz to trapezoid

Keep trapz as an undocumented alias.  Addresses part of gh-12924.

* MAINT: rename stats.trapz to trapezoid

Keep trapz as an undocumented alias.  Closes gh-12924.

* STY: fix two tiny linting things
2020-10-16 14:42:09 -04:00
Ralf Gommers 77c28dd73e DOC: add section on global optimizers to tutorial. 2018-12-06 21:15:45 -08:00
Peter Cock 80e76d43f0 Fix pycodestyle E305 using autopep8 (#8391)
* Fix pycodestyle E305 using autopep8

Using pycodestyle v2.3.1 (successor to the tool pep8) to check
coding style, there were hundreds of cases of:

E305 expected 2 blank lines after class or function definition

These were fixed using:

autopep8 --select E305 --in-place ...

This would close issue #8388, cross reference #8384 for updating
TravisCI to use pycodestyle inplace of pep8 for style checks.

* TravisCI/tox can now enforce pep8 E305
2018-02-25 11:26:54 -05:00
Andrew Nelson ce297050ae MAINT: transition examples to python3
DOC: change to print functions

DOC: lot 1

DOC: lot 2

DOC: csgraph.rst

DOC io.netcdf refguide

DOC: encoding should be UTF-8?

DOC: fixed ndimage + csgraph examples

CI: remove refguide test from 2.7

DOC: finally sorted csgraph doc example

DOC: fixed refguide for cKDTree

MAINT: use np.c_ instead of list(zip(
2017-07-27 17:52:54 +10:00
Warren Weckesser 23730b5393 DOC: stats: Update stats tutorial
* Use the print function
* Fix some outputs
* A few other bits of copy-editing of code
2017-03-07 23:09:02 -05:00
Jakub Wilk af80fb5694 DOC: fix typos 2016-06-12 12:56:23 +02:00
Ralf Gommers a13e116d14 MAINT: remove optimize.anneal for 0.16.0 (was deprecated in 0.14.0).
Closes gh-1653, gh-4042, gh-4009, gh-1402.
2015-01-04 13:20:01 +01:00
Christian Brueffer 682e033497 Misc PEP8 fixes. 2014-10-21 14:50:13 +02:00
Evgeni Burovski ba9cf21dba DOC: remove `import scipy as sp` abbreviation here and there 2014-08-31 12:37:19 +01:00
Christian Brueffer a040d53c9a Remove spurious EOL and EOF whitespace. 2013-08-15 14:09:12 +02:00
Jacob Stevenson e4372512dc fix release notes section heading
also, add basinhopping to a few places in the documentation where anneal
was mentioned
2013-01-31 21:34:49 +00:00
Denis Laxalde 3e31d21752 DOC: use root instead of nonlin solver in optimize tutorial 2012-06-05 15:38:37 -04:00
Pauli Virtanen 59f06e37d8 STY: CRLF -> LF conversion 2011-03-11 10:57:10 +01:00
rgommers 68b846cff1 DOC: improve formatting of docs, eliminate old-style section headers. 2011-02-20 13:30:33 +00:00
Pauli Virtanen 675cfd748e DOC: optimize/tutorial: add an example of preconditioning when using the matrix-free Newton-Krylov solver 2010-09-07 21:53:41 +00:00
josef 73a47e8a20 correct plot directives in stats.tutorial 2009-08-26 18:44:55 +00:00
Jarrod Millman 3f374927ec minor reorganization 2008-12-14 14:05:54 +00:00
Pauli Virtanen 072b6b10ac tutorial: move examples and plot codes to body, for easier editing. Make use of the new plot directive. 2008-12-03 23:23:53 +00:00
Pauli Virtanen b3900ddebe docs: Ensure that examples in the tutorial run with current Scipy 2008-11-16 12:50:11 +00:00
Pauli Virtanen 214abb80f7 Moving scipy-docs under the main Scipy tree 2008-11-16 11:34:49 +00:00