Series.str.toUpperCase

Converts all characters to uppercase.

danfo.Series.str.toUpperCase() [source]

Parameters: None

Returns: Series (String element)

Example

Convert all characters in each string element to capital letter

Node
Browser
Node
const dfd = require("danfojs-node")
let data = ['lower boy', 'CAPITALS', 'sentence', 'SwApCaSe']
let sf = new dfd.Series(data)
sf.str.toUpperCase().print()
Browser
Output
Output
╔═══╤══════════════════════╗
║ │ 0 ║
╟───┼──────────────────────╢
║ 0 │ LOWER BOY ║
╟───┼──────────────────────╢
║ 1 │ CAPITALS ║
╟───┼──────────────────────╢
║ 2 │ SENTENCE ║
╟───┼──────────────────────╢
║ 3 │ SWAPCASE ║
╚═══╧══════════════════════╝