Redian新闻
>
How to char <--> int in Matlab?
avatar
How to char <--> int in Matlab?# Programming - 葵花宝典
z*u
1
Hi, every bull man. I have a simple problem for you guys.
All the issue starts with saving data in Excel. I made a loop and at the end
write a group of data into the Excel file columnly. Of course, I don't
wanna overwrite existing data. So I need to tell it which column to write, e
.g., 'A' or 'B' etc. So I have to be able to transfer integer into character
'A', 'B' etc, right? I tried to run 'A'+1-1 and got 65, so it seems 'A' is
mapped uniquely to the int 65. So is there a function to transfer
avatar
z*u
2
用中文再写一遍。
请问Matlab什么函数可以把'A'变成65,或者把65变成'A'?
多谢多谢!
avatar
z*u
3
I found them.
char(65)='A'
double('A')=65
Thanks anyway.
相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。