Operator introduction
Description
Bullet-point line ratio calculator - calculates the proportion of bullet-pointed lines in text
Key features
- Bullet-point detection: Automatically identifies lines in the text that start with a bullet point
- Ratio calculation: Calculates the ratio of bullet-pointed lines to the total number of lines
Application scenarios
- Text quality assessment
- Data cleaning and preprocessing
Technical characteristics
- Supports multiple bullet points: •, -, ·, ●, ▪, —, *, and so on
- Accurate identification: Only counts lines that start with a bullet point
- Result range: 0-1, the closer to 1, the more bullet-pointed lines there are
- Intelligent filtering: Automatically filters blank lines without affecting the calculation
Daft invocation
Operator parameters
Input column name | Note |
|---|
texts | The text column to be processed; elements must be of string type |
Output
The bullet-point line ratio column contains floating-point numbers representing the ratio of bullet-pointed lines.
Examples
The following code demonstrates how to use Daft to run the operator and calculate the proportion of bullet-pointed lines in text.