JOHN Swinney has defended his government’s record on education claiming new statistics reveal a slight narrowing of Scotland’s attainment gap.

But the figures laid bare the challenge facing ministers with many primary school leavers in the country’s most deprived areas still not meeting the expected levels in literacy and numeracy.

In the most deprived parts of Scotland in 2017-18, 59% of P7 pupils met the expected standards in literacy, compared to 83% in the most affluent communities.

While 66% of P7 pupils in the poorest areas hit targets for numeracy, that was dwarfed by the 86% of kids in the richest parts of the country.

In S3, 95% of students from the least deprived areas met the expected standards under Curriculum for Education for literacy, compared to 81% of youngsters from the most deprived areas.

In numeracy the situation was similar, with 96% of those from the least deprived areas reaching the expected standards, compared to 82% of those from the poorest areas.

Swinney said he was “encouraged” that, compared to last year’s figures, the attainment gap had “narrowed slightly”.

He added: “There is an increased proportion of primary pupils assessed as achieving the expected levels of Curriculum for Excellence by up to four percentage points.”

The Education Secretary also welcomed new statistics showing schools employed 51,959 teachers, including those working in early learning and childcare centres.

Of those 24,899 are primary teachers, which represents the highest number since 1980, the Government said.

Overall that means there are 447 more teachers than there were in the previous year.

EIS general secretary Larry Flanagan warned that it still wasn’t enough to cope with the number of children in Scotland’s schools.

Scotland’s schools had 693,251 pupils in 2018, an increase of 4611.

That meant the pupil-to-teacher ratio was unchanged at 13.6. The average primary school class size also stayed at 23.5 children.

Flanagan said: “We also have a large increase in the number of pupils in our schools which means that pupil-teacher ratios remain at an absolute standstill compared to last year.”

Tory education spokeswoman Liz Smith said: “Notwithstanding a very welcome rise in teacher numbers, there remain some grim statistics which will make worrying reading for parents and teachers”.

Labour’s Iain Gray said the figures showed “that the poorest young people are being failed badly” by the SNP government.