BOSTON (AP) — Television ad spending on Massachusetts ballot questions has approached $5.8 million with Election Day less than two weeks away.

Virtually all of that spending has come from two groups: The Coalition to Protect Mass Jobs, which is hoping to persuade voters to reject a ballot question that would repeal the state's casino law, and No on Question 2: Stop Forced Deposits, which opposes a question that would expand the state's bottle deposit law.

Nationally, TV ad spending on ballot issues totaled about $119 million through Monday, including $10.4 million on local ballot measures.

That's according to a Center for Public Integrity, which reviewed data about political advertising on national cable and broadcast television in each of the country's 210 media markets.

The organization used research from Kantar Media/CMAG, which tracks political advertising and offers a widely accepted estimate of the money spent to air each spot between Jan. 1, 2013, and Monday.

California topped the list, with groups there having spent more than $58 million, followed by Colorado ($15.9 million), Oregon ($7.7 million) and Massachusetts.

According to the study, the Coalition to Protect Mass Jobs has spent an estimated $3.3 million on television ads, which have run about 2,800 times while the No on Question 2 committee spent an estimated $2.5 million on television ads, which have run more than 1,200 times.

The figures only represent part of the money spent on political advertising. They don't include money spent on ads on radio, online and direct mail. They also don't reflect ads that aired on local cable systems or the cost of making the ads.

Groups supporting and opposing all four Massachusetts ballot questions already have raised a total of nearly $20.7 million and spent more than $17 million of that, according to an Associated Press review of records filed with the state.

The No On Question 2: Stop Forced Deposits committee is funded largely by supermarket chains, which would have to deal with the added volume of extra bottles to be returned, and the Washington-based American Beverage Association, the lobbying group for soft drink companies.

The group has raised more than $8.7 million — and spent nearly as much — trying to kill a question that would expand the state's bottle deposit law to include bottled water and noncarbonated beverages.

Supporters of the ballot question, including environmental groups like the Massachusetts Sierra Club, have raised just over $1 million and have already spent more than $900,000 of that.

The Coalition to Protect Jobs has raised more than $7.5 million and spent $6.2 million since the start of the campaign and is funded largely by casino companies that already have been awarded licenses in Massachusetts including Wynn Resorts, MGM Resorts International, and Penn National.

By contrast, the Repeal the Casino Deal Committee has raised $436,000, spending just under $415,000.

Campaign finance data rarely, if ever, present a hard total for all spending. A total like that usually is not available for months or sometimes years after the fact, and still is likely to miss some money.