在MatLab环境中,如何将Logical转换为矩阵形式?
例如,请考虑以下逻辑:
Run Code Online (Sandbox Code Playgroud)[0 1 0 1] [0 0 1 0] [1 0 1 1] [0 1 0 0]
我尝试运行一个简单的代码如下:
Create Table weather (
city varchar(80),
temp_lo int,
temp_hi int,
prcp real,
date date
);
Insert Into weather Values ('A', -5, 40, 25, '2018-01-10');
Insert Into weather Values ('B', 5, 45, 15, '2018-02-10');
Create Table cities (
city varchar(80),
location point
);
Insert Into cities Values ('A', '(12,10)');
Insert Into cities Values ('B', '(6,4)');
Insert Into cities Values ('C', '(18,13)');
Select * From cities, weather Where city = 'A'
Run Code Online (Sandbox Code Playgroud)
但我得到的是
错误:列引用"city"不明确.
我的代码出了什么问题?