KONVERSI_FORMAT_GPS_SECARA_OTOMATIS_MENGGUNAKAN_EXCEL.pdf
-
Upload
ritasilabannatalie -
Category
Documents
-
view
225 -
download
0
Transcript of KONVERSI_FORMAT_GPS_SECARA_OTOMATIS_MENGGUNAKAN_EXCEL.pdf
-
8/9/2019 KONVERSI_FORMAT_GPS_SECARA_OTOMATIS_MENGGUNAKAN_EXCEL.pdf
1/3
KONVERSI FORMAT GPS SECARA OTOMATIS MENGGUNAKAN EXCEL
Abstraksi
Pada saat bekerja mengelola data asset PT PLN yang lokasinya tersebar secara luas, tentunya
memerlukan bantuan keterangan koordinat GPS agar bisa dengan mudah memonitor lokasiasset dengan menggunakan program pemetaan seperti Map Info, Arc View, Global Mapper,
Google Map, Google Earth dan lain sebagainya. Hasil para surveyor di lapangan terkadang
memberikan output koordinat gps dengan format yang berbeda-beda, seperti decimal degree,degree minute seconds, wgs84, utm dan lain sebagainya. Hal ini akan menyulitkan proses entri
database karena format data yang tidak seragam, sehingga perlu tool untuk mengkonversi
semua data secara otomatis.
1. Tujuan
Tulisan ini bertujuan memberikan penjelasan tentang langkah-langkah melakukan konversi data
gps dari derajat decimal ke derajat menit detik atau sebaliknya dengan menambahkan fungsi pada formula excel
2. Pembahasan
a. Petunjuk Penggunaan Konversi Decimal Degrees ke Degrees Minutes Seconds
Buka Excel dan tekan ALT+F11 untuk memulai Visual Basic editor.Pada menu Insert, klik Module.
Masukan kode program untuk Convert_Degree custom function seperti yang telah di jelaskan di
atas pada sheet module.Berikut kode program untuk Convert_Degree custom function
Function Convert_Degree(Decimal_Deg) As VariantWith Application
'Set degree to Integer of Argument Passed
Degrees = Int(Decimal_Deg)
'Set minutes to 60 times the number to the right'of the decimal for the variable Decimal_Deg
Minutes = (Decimal_Deg - Degrees) * 60
'Set seconds to 60 times the number to the right of the'decimal for the variable Minute
Seconds = Format(((Minutes - Int(Minutes)) * 60), "0")
'Returns the Result of degree conversion'(for example, 10.46 = 10~ 27 ' 36")
Convert_Degree = " " & Degrees & "° " & Int(Minutes) & "' " _
& Seconds + Chr(34)End With
End Function
Tekan ALT+F11 untuk kembali ke excel.
Pada cell A1 ketik 10.46.
-
8/9/2019 KONVERSI_FORMAT_GPS_SECARA_OTOMATIS_MENGGUNAKAN_EXCEL.pdf
2/3
Pada cell A2 ketik seperti formula berikut:
=Convert_Degree(A1)
Maka formula menghasilkan 10°27'36"
b. Petunjuk Penggunaan Convert Degrees Minutes Seconds to Decimal Degrees.txt
Untuk menggunakan fungsi ini, buat formula konversi, seperti contoh berikut:Buka Excel dan tekan ALT+F11 untuk memulai Visual Basic Editor.
Pada menu Insert, klik Module.
Masukkan contoh code untuk Konversi Decimal custom function yang telah di jelaskan dimodule sheet.
Berikut kode program untuk Convert_Decimal custom function
Function Convert_Decimal(Degree_Deg As String) As Double
' Declare the variables to be double precision floating-point.Dim degrees As Double
Dim minutes As DoubleDim seconds As Double
' Set degree to value before "°" of Argument Passed.
degrees = Val(Left(Degree_Deg, InStr(1, Degree_Deg, "°") - 1))' Set minutes to the value between the "°" and the "'"
' of the text string for the variable Degree_Deg divided by
' 60. The Val function converts the text string to a number.minutes = Val(Mid(Degree_Deg, InStr(1, Degree_Deg, "°") + 2, _
InStr(1, Degree_Deg, "'") - InStr(1, Degree_Deg, _
"°") - 2)) / 60' Set seconds to the number to the right of "'" that is
' converted to a value and then divided by 3600.
seconds = Val(Mid(Degree_Deg, InStr(1, Degree_Deg, "'") + _
2, Len(Degree_Deg) - InStr(1, Degree_Deg, "'") - 2)) _/ 3600
Convert_Decimal = degrees + minutes + seconds
End FunctionTekan ALT+F11 untuk kembali ke excel.
Pada cell A1 ketik formula berikut:
=Convert_Decimal("10° 27' 36""")Catatan: Anda perlu mengetik tiga tanda quotation (""") di khir formula untuk menyeimbangkan
tanda quotation untuk seconds dan tanda quotation untuk teks berikutnya. Cell referensi tidak
memerlukan tanda quotation.Formula menghasilkan 10.46
-
8/9/2019 KONVERSI_FORMAT_GPS_SECARA_OTOMATIS_MENGGUNAKAN_EXCEL.pdf
3/3
3. Kesimpulan
Metode ini sangat mudah di terapkan di Microsoft Excell untuk konversi data koordinat gps
4. Penulis
Ervin Saputra, 8106354Z, PT PLN (Persero) AP2B KSKT
5. Referensi Komunitas GIS (internet)