Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Syndicate_Admin
Administrator
Administrator

Traducir una columna con Python usando la biblioteca de blobs de texto

¡Hola! Estoy intentando traducir una columna de mi tabla usando la biblioteca TextBlob de python. este es el mejor código. de textblob import TextBlob Traducción def(texto): blob = TextBlob (texto) return str(blob.translate(from_lang = 'pt', to = 'en')) dataset['translation'] = dataset['IMDB Description'] .apply(traducción) Genera el siguiente error.

El argumento 'text' pasado a '__init__(text)' debe ser una cadena, no
vgferreira_0-1669213483672.png

pero mi columna CardDescription tiene formato de texto, hice una prueba usando una variable de cadena y funcionó. No sé la razón del error, ¿alguien puede ayudarme? ¡Gracias ahora!

0 REPLIES 0

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Kudoed Authors