Removing multiple values using if else statements?
You can use the ROW_NUMBER() function to produce a windowed record ID for each row, grouped by RoomCode and Time as per this db&lt;>fiddle. 

For each of the semi-duplicate rows (where RoomCode and Time are the same but Occupancy is different) this produces an incrementing number based on occupancy in descending order (so 1 = 1 and 0 = 2).

Place this in a CTE and then inner join your table to the CTE based on all columns except Occupancy where the ROW_NUMBER() pseudo column is > 1.

Example:

;WITH DataCTE AS (
SELECT RoomCode, Occupancy, Time, DayFromDate, 
ROW_NUMBER() OVER (PARTITION BY RoomCode, Time ORDER BY Occupancy DESC) AS RN
FROM DataPoints
)

DELETE d1
FROM DataPoints d1
INNER JOIN DataCTE d2
ON d1.RoomCode = d2.RoomCode
 AND d1.Occupancy = d2.Occupancy
 AND d1.Time = d2.Time
 AND d1.DayFromDate = d2.DayFromDate
WHERE d2.RN &gt; 1


Result:

RoomCode    Occupancy   Time    DayFromDate
EW1A-03-08  0   07/10/2019 08:00:00     Wednesday
EW1A-03-08  1   07/10/2019 08:30:00     Wednesday
EW1A-03-08  1   07/10/2019 09:00:00     Wednesday
EW1A-03-08  1   07/10/2019 09:30:00     Wednesday
EW1A-03-08  1   07/10/2019 10:00:00     Wednesday
EW1A-03-08  1   07/10/2019 10:30:00     Wednesday
EW1A-03-08  0   07/10/2019 11:00:00     Wednesday
EW1A-03-08  0   07/10/2019 11:30:00     Wednesday
EW1A-03-08  0   07/10/2019 12:00:00     Wednesday
EW1A-03-08  0   07/10/2019 12:30:00     Wednesday
EW1A-03-08  0   07/10/2019 13:00:00     Wednesday
EW1A-03-08  0   07/10/2019 13:30:00     Wednesday
EW1A-03-08  0   07/10/2019 14:00:00     Wednesday
EW1A-03-08  0   07/10/2019 14:30:00     Wednesday
EW1A-03-08  0   07/10/2019 15:00:00     Wednesday
EW1A-03-08  1   07/10/2019 15:30:00     Wednesday
EW1A-03-08  0   07/10/2019 16:00:00     Wednesday


You may need to massage this example and include additional columns in the PARTITION BY clause to ensure you're only selecting the correct near-duplicates but this should achieve the result you're after.

P.S. Its always a good idea in questions to include DDL (table definition), DML (INSERT statement with example data) and expected results to help clarify what you're trying to achieve.