Contenu principal

Format JSON

Format JSON (JavaScript® Object Notation)

JavaScript Object Notation (JSON) est un format d’échange de données basé sur le langage de programmation JavaScript. Dans MATLAB®, vous pouvez décoder et encoder du texte au format JSON. Vous pouvez également importer les données d’un fichier JSON dans MATLAB sous forme de structure (depuis R2023b), de dictionnaire (depuis R2024b), de table (depuis R2026a) ou de timetable (depuis R2026a). Vous pouvez écrire le contenu d’une structure, d’un dictionnaire, d’une table ou d’une timetable dans un fichier JSON.

Fonctions

développer tout

jsondecodeDecode JSON-formatted text
jsonencodeCreate JSON-formatted text from structured MATLAB data
readstructCreate structure array from file
writestructWrite structure array to file
readdictionaryCreate dictionary from file (depuis R2024b)
writedictionaryWrite dictionary to file (depuis R2024b)
readtableCreate table from file
writetableWrite table to file
readtimetableCreate timetable from file
writetimetableWrite timetable to file
detectImportOptionsCreate import options based on file content
jsonImportOptionsImport options object for JSON files (depuis R2026a)
getvaroptsGet variable import options
setvaroptsSet variable import options
setvartypeSet variable data types

Rubriques