D3學習之:D3.js中的12中地圖投影方式

特別感謝:1.【張天旭】的D3API漢化說明。已被引用到官方站點;git

2.【饅頭華華】提供的ourd3js.com上提供的學習系列教程,讓咱們這些新人起碼有了一個方向。
github

不得不說,學習國外的新技術真的是一個很是艱苦的過程。sql

在學習D3繪製地圖的過程當中。有朋友建議看一下當中投影的說明比較好。因而,憑藉我這半吊子不到的英文水平,大體給翻譯了下來,僅供參考:數組

原文連接:https://github.com/mbostock/d3/wiki/Geo-Projections#albersapp

D3中一共提供了12種地圖投影方式(每一種說明後面的藍色字體是樣例的超連接),分別例如如下:ide

# d3.geo.albersUsa()

The Albers USA projection is a composite projection of four Albers projections 
designed to display the forty-eight lower United States alongside Alaska and Hawaii.
 Although intended for choropleths, it scales the area of Alaska by a factor of 0.35x (a lie factor of 3); 
 Hawaii is shown at the same scale as the lower forty-eight.

The Albers USA projection does not support rotation or centering.

譯:阿伯斯投影
阿伯斯投影是被設計用4個阿伯斯投影把美國的阿拉斯加州和夏威夷州顯示到本圖旁邊的複合投影,雖然用了等值線圖。它把阿拉斯加州縮放了0.35倍,
夏威夷州雖然仍是同樣的比例,但偏移了48度(沒查過距離資料。只是夏威夷確實是向東移動了)。

阿伯斯投影不支持旋轉和設定中心。
# d3.geo.azimuthalEqualArea()

The azimuthal equal-area projection is also suitable for choropleths.
 A polar aspect of this projection is used for the United Nations logo.
 
等面積方位投影
等面積方位投影也適合等值線圖,這個投影的極座標方向被用來做爲聯合國圖標。

# d3.geo.azimuthalEquidistant()
The azimuthal equidistant projection preserves distances from the projection’s center:
the distance from any projected point to the projection’s center is proportional to the great arc distance.
Thus, circles around the projection’s center are projected to circles on the Cartesian plane.
This can be useful for visualizing distances relative to a point of reference, such as commute distances.

等距方位投影
等距方位投影保存着投影中心,從投影上的不論什麼點到投影中心的弧線距離都是成比例的。所以。圓形的投影環繞着投影中心被投影在用圓圈住的一個笛卡爾平面上。
這可以用於將距離參考點的數據可視化顯示。比方通勤距離。
# d3.geo.conicConformal()
Lambert’s conformal conic projection projects the globe conformally onto a cone.
圓錐共形投影
蘭伯特的圓錐共形投影將地球投影在一個圓錐上。

# conicConformal.parallels([parallels])
If parallels is specified, sets the projection’s standard parallels to the specified two-element array of latitudes (in degrees) and returns the projection.
 If parallels is not specified, returns the current parallels.
 圓錐共形投影.平行線([經緯度數組])
 假設指定平行線。使投影的標準平行變爲以經緯度(單位:度)表示的兩個元素的數組並返回投影。假設不指定平行線,返回當前的投影。
# d3.geo.conicEqualArea()
The Albers projection, as an equal-area projection, is recommended for choropleths as it preserves the relative areas of geographic features.
圓錐等面積投影
阿伯斯投影,做爲一種等面積投影,被推薦做爲等值線圖。因爲它保留了相對區域的地理特徵。
# conicEqualArea.parallels([parallels])
If parallels is specified, sets the Albers projection’s standard parallels to the specified two-element
array of latitudes (in degrees) and returns the projection. If parallels is not specified, returns the current parallels.
To minimize distortion, the parallels should be chosen to surround the projection’s center.
圓錐等面積投影.平行線([經緯度數組])
假設指定平行線,設置阿伯斯投影的標準平行變爲以經緯度(單位:度)表示的兩個元素的數組並返回投影。假設不指定平行線,返回當前的投影。
爲了下降失真。平行線應該選擇在投影中心周圍。
# d3.geo.conicEquidistant()
圓錐等距投影
# conicEquidistant.parallels([parallels])

If parallels is specified, sets the projection’s standard parallels to the specified two-element array of latitudes (in degrees) and returns the projection.
 If parallels is not specified, returns the current parallels.
 圓錐等距投影.平行線(數組)
 假設指定平行線,設置阿伯斯投影的標準平行變爲以經緯度(單位:度)表示的兩個元素的數組並返回投影。假設不指定平行線,返回當前的投影。
# d3.geo.equirectangular()

The equirectangular, or plate carrée projection, is the simplest possible geographic projection: the identity function.
 It is neither equal-area nor conformal, but is sometimes used for raster data. See raster reprojection for an example;
 the source image uses the equirectangular projection.
 相等矩形投影
 相等矩形投影,或者叫普拉特方形投影(貌似這是法國的叫法),是最簡單可能的地理投影:標記功能(正比例函數。都是網上釋義,我也搞不清楚這裏的意思)。
 它既不等面積也不保持形狀,只是有時候用於柵格數據。這個站點是一個用相等矩形投影的樣例。
# d3.geo.gnomonic()
The gnomonic projection is an azimuthal projection that projects great circles as straight lines. See the interactive gnomonic for an example.
球心投影
球心投影是一種方位投影。它接二連三地投影一個巨大的包圍圈。

這個站點就是一個樣例(你可以想象一下從地球儀中心看地球地圖的感受)。函數

# d3.geo.mercator()

The spherical Mercator projection is commonly used by tiled mapping libraries (such as OpenLayers and Leaflet).
For an example displaying raster tiles with the Mercator projection, see the d3.geo.tile plugin.
It is conformal; however, it introduces severe area distortion at world scale and thus is not recommended for choropleths.

墨卡託投影
球形的墨卡託投影在映射平鋪的數據時是最常常使用的,好比用墨卡託投影顯示柵格,好比http://bl.ocks.org/mbostock/4150951這個頁面。
它是正形的,然而,它將地圖上的不少地方進行了嚴重變形,所以。不建議使用等值線圖。
# d3.geo.orthographic()

The orthographic projection is an azimuthal projection suitable for displaying a single hemisphere;
the point of perspective is at infinity. See the animated world tour and interactive orthographic for examples.
 For a general perspective projection, see the satellite projection.
 正射投影
 正射投影也是一種方位投影。它適合顯示一個半球:角度無窮大。
# d3.geo.stereographic()

The stereographic projection is another perspective (azimuthal) projection. The point of perspective is on the surface of the sphere, looking in;
 it is thus commonly used for celestial charts. See the interactive stereographic for an example.
 極射赤平投影
 極射赤平投影是還有一個角度的方位投影。它的視角至關於站在地球的表面向裏面看(跟球心投影相反),它所以被經常常使用於天體圖。
# d3.geo.transverseMercator()

The transverse Mercator projection.
橫向墨卡託投影
就是一個橫向的墨卡託投影。
注:由於原頁面引用的全是D3繪製的圖像,因此沒法路徑引用查看圖片。大家懂的~
相關文章
相關標籤/搜索