How to Add Apostrophes in MATLAB
- 1). Open the source code of your MATLAB program in Notepad or in an integrated development environment application.
- 2). Locate the string that contains the apostrophe.
- 3). Place an additional apostrophe before the apostrophe contained in the quote. By doubling the apostrophe, you will instruct MATLAB to escape the character.
- 4). Save your source code file.