--- title: donchian description: This page provides information on Donchian Channels, an indicator comprising upper and lower bands around a midrange or median band. It includes details of the parameters for its usage. keywords: - Donchian Channels - moving average calculations - upper and lower bands - highest and lowest price - N periods - security - Donchian Channel - N_LENGTH_UPPER - N_LENGTH_LOWER --- import HeadTitle from '@site/src/components/General/HeadTitle.tsx'; Donchian Channels are three lines generated by moving average calculations that comprise an indicator formed by upper and lower bands around a midrange or median band. The upper band marks the highest price of a security over N periods while the lower band marks the lowest price of a security over N periods. The area between the upper and lower bands represents the Donchian Channel. ### Usage ```python donchian [-u N_LENGTH_UPPER] [-l N_LENGTH_LOWER] ``` --- ## Parameters | Name | Description | Default | Optional | Choices | | ---- | ----------- | ------- | -------- | ------- | | n_length_upper | length | 20 | True | range(1, 100) | | n_length_lower | length | 20 | True | range(1, 100) | ![donchian](https://user-images.githubusercontent.com/46355364/154310472-6cd5805f-b87f-4668-85a1-3e5dd7267848.png) ---