Skip to content
All library documents

Chinese Beverage and Alcohol Stock Screen by Turnover and Daily Return

Article Qlib

Summary

This stock screen targets companies associated with beverage and alcohol imports or exports. It filters for turnover between 3% and 12% and a daily price change above -5% but below 2.6%. The article presents these as industry, liquidity, and price-movement criteria; its code examples also contain additional data filters that do not consistently match the stated final rules.

The author cautions that the screen omits company fundamentals and competitive position, and suggests incorporating financial measures and industry prospects. The document provides formulas and sample code, but no backtest, portfolio construction, or evidence of returns. It is therefore a set of screening conditions rather than a validated trading strategy.

Key ideas

  • The stated screen focuses on beverage and alcohol import or export businesses.
  • It sets a turnover band of 3% to 12% and a daily return between -5% and 2.6%.
  • The article warns that the filters do not assess company fundamentals or competitive strength.
  • The examples contain extra filters and no reported performance test.

Tags

Full text
# installation


.. _installation:

============
Installation
============

.. currentmodule:: qlib

.. important::

   Upgrading an existing workflow? Read :ref:`config_migration` before using
   local Python modules, custom expressions, or extension registries. The guide
   describes unreleased source changes; a PR checkout, ``main``, and a tagged
   or PyPI release can differ. Use examples and documentation matching your
   installed revision.


.. important::

   **Unreleased upgrade notice for new source builds:** recorder artifact loading
   is restricted by default. Reloading executable models, datasets or workflow
   objects requires explicit ``trusted=True`` after verifying their source and
   storage; supported data-only reads and fresh in-memory training need no opt-in.
   Follow :ref:`artifact_loading_migration` before upgrading existing workflows.
   Merging into ``main`` affects source installs before a new PyPI release.
   This change is unreleased until included in a tagged release, whose upgrade
   notes should link to that guide.


``Qlib`` Installation
=====================
.. note::

   `Qlib` supports both `Windows` and `Linux`. It's recommended to use `Qlib` in `Linux`. ``Qlib`` supports Python3, which is up to Python3.8.

Users can easily install ``Qlib`` by pip according to the following command:

.. code-block:: bash

   pip install pyqlib


Also, Users can install ``Qlib`` by the source code according to the following steps:

- Enter the root directory of ``Qlib``, in which the file ``setup.py`` exists.
- Then, please execute the following command to install the environment dependencies and install ``Qlib``:

   .. code-block:: bash

      $ pip install numpy
      $ pip install --upgrade cython
      $ git clone https://github.com/microsoft/qlib.git && cd qlib
      $ python setup.py install

.. note::
   It's recommended to use anaconda/miniconda to setup the environment. ``Qlib`` needs lightgbm and pytorch packages, use pip to install them.



Use the following code to make sure the installation successful:

.. code-block:: python

   >>> import qlib
   >>> qlib.__version__
   <LATEST VERSION>

Shown in full with attribution under the source's licence. Licence: MIT

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.